2
votes

I have a problem with textures in LWJGL:


(source: socplay.pl)

It looks like some sort of texture artifact. What is this problem and how can I fix it?

1
Could be Z-fighting. - user253751
did you locate the problem in your code? - dokaspar

1 Answers

0
votes

You haven't posted much detail, but this looks like Z-fighting to me.

Z-fighting is a phenomenon that occurs if you render two (or more) polygons that almost exactly overlap, but with different textures, colours or lighting. Because the two polygons are in almost exactly the same place, small floating-point errors can cause the "which polygon is in front" test to be unpredictable on a pixel-by-pixel basis.