How to prevent z-fighting with fake shadows?

I have a plane that is actually a fake shadow, I just baked it using Photoshop…

I have two planes and each plane have a shadow that I put in a THREE.Group. The problem is, sometimes when they overlap eachother one totally disappear or make things really weird!

Screenshot

As you can see in the screenshot above, the first shadow is visible but the second isn’t.

How can I overlap those two shadows together? Is there a way to do that? I would like to know if it’s actually possible to make two fake shadows appear together.

Cheers,

I’m not sure what exactly you are trying to do here, but in general if you must have two very close planes and don’t want them to cause z-fighting, you can work around the problem by manually setting their renderOrder.

2 Likes

mesh.renderOrder

or mesh.position.y = 0.0001

or material.polygonOffset

1 Like