Bad Z-Fighting on iPhone / iPad (WebGL1 vs WebGL2?)

Hi,

I’ve been fighting this bug for month now, but for some reason, I have very bad z-fighting on the iPad, and I don’t have it on desktop browsers. I thought maybe it was a webgl 2 thing - but I don’t get the z-fighting on desktop safari. Does zOffset not work on iPhone / iPad? Is there some other bug that causes the depth buffer to have less precision on mobile devices?

Ben
www.cryptovoxels.com

Did you try to reduce the camera.maxZ or increase camera.minZ to confirm the depth fight

From what I’m seeing, it should be supported:

can you repro in the playground?

Heya @Deltakosh, I should have tried to repro in the playground first - I edited maxZ and minZ like you said and the problem has been minimised to the point it’s not an issue any more. It still seems that iOS devices have less precision in the depth buffer - but it’s solved for now.

I love this forum, so helpful, thank you and good luck with babylon 4! :slight_smile:

1 Like

thank you:)