Mesh disappear then reappear while rotating

hello there,
I am working on a bar chart, I put bars in a 3 side stage (ground, back and side)
sides of the stage are PlaneGeometry and MeshLambertMaterial with opacity.
some bars disappearfor a second when rotating the scene. if the rotation is slower bars dont disappear
I think its some kind of renderer problem but dont know how to fix
please help.

Probably a depth sorting issue. In general, it’s hard to analyze such problems without a live example. Depending on your scene graph’s structure, it might be possible to mitigate the issue by properly configuring Material.depthWrite or Object3D.renderOrder.

2 Likes

basically watching from one side is ok but when the scene rotation comes to corner it breaks down and some bars disappears and reappears it only does this when entering the back side of the stage and leaving the back side of the stage.
I will look for depthWrite and renderOrder immediately.
thanks .

@eomerb do you inner bars have transparent property set to true?

yes
for now bars material options: transparent:true, opacity:1
opacity value can be changed

Try to set it to false (for intter bars only, not for the outer box).

it worked but I need them to be transparent also (not as transparent as outer box)

You can set depthWrite = false in the walls. That way they won’t occlude the bars.

But as @Mugen87 says, some bars could occlude others.

2 Likes

it worked
now the bars dont disappear
the walls appear on some bars a little late but not gonna rotate full so no problem
thank you all

1 Like