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,