Problems with opacity

Hello everyone.
I am having problems in my playground when it comes to displaying several objects with opacity.
As you rotate the camera, objects do a small opacity change effect.

Is it possible to correct this effect?
A greeting and thanks in advance.

Iā€™m actually experiencing the very same issue. So Iā€™m gonna bookmark this.
I found that when using a different material, the issue is gone but with this PG, assigning a duplicate material to each mesh seems a bit ā€˜undoableā€™. Also, there are no meshes crossing an other (same as in my project), so why is it that itā€™s still breaking?ā€¦ Do we really need to use OIT for this? Iā€™m eager to read the answer.

1 Like

The number of elements would be more than 1000 hexagons, it is not possible to assign a different material to each of the objects.

Hi i edited your playground and have found somewhat of a fix for the problem. You can look it up at the bottom of this playground link: https://playground.babylonjs.com/#LREGM0#1

Seems like the backgroundPlaneMaterial was the problem because itā€™s alpha mode was set to ā€œcombineā€ and all hexagons to ā€œaddā€ which wonā€™t work together correctly as it seems. But by adjusting the alphaMode and alpha of the background plane it can be fixed.

2 Likes

The result is perfect.
Thank you very much for your help.

Well, This doesnā€™t really look like a true solution to me.
It radically changes the effect of transparency and alpha blending, so yes it works (may be in this case) but I donā€™t find this satisfying (at least for my case).

I have fixed the problem without changing the alpha type of the ground.
I have changed the render group id of the hexagon.

2 Likes

Yes, thatā€™s good it worked for you. However, in my case this solution is unacceptable. Iā€™m still struggling with it but, same as you, will hopefully get there :wink:
GL with your project,