0
$\begingroup$

The leaves are behaving as if depth-buffering is disabled, so those closer are being rendered over by those further away.

I've looked for a solution or someone with a similar problem, but haven't been able to find anything relevant. I get the feeling the solution is something stupidly simple, but it has eluded me so far. I would rather have uploaded a blend file, but I cannot for the life of me figure out how to do it on this website, so I've taken 3 screen shots of the problem, each one slightly rotated to hopefully help you see what's going on.

The problem doesn't happen when the leaves are instanced onto the branches, but the moment all the objects are combined into one mesh, sharing one material, this starts happening. I've tried using images both with an alpha component, and ones without, and it makes no difference. enter image description here enter image description here enter image description here

$\endgroup$

1 Answer 1

1
$\begingroup$

The problem that you are faced is well known. As of now Eevee does not support per-fragment (pixel) sorting or per-triangle sorting. Only per-object sorting is available and is automatically done on all transparent surfaces based on object origin.

Then you convert instances, all per-instance origins removed, and alpha sorting works as the model is a single object from alpha sorting perspective.

So as a compromise, you can enable Alpha Clip Blend mode in material settings:

enter image description here

$\endgroup$
1
  • $\begingroup$ I could kiss you! Thank you very much. $\endgroup$ Commented May 8, 2023 at 22:44

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .