0
\$\begingroup\$

I was developing a C++ implementation of OpenGL for Android and I noticed those weird artifacts that formed between 2 intersecting objects (or triangles) :

Here are the artifacts on Android [Here are the artifacts on Android]

The weird thing is that exactly the same library, running on my windows machine, with exactly the same shaders is not giving the same results (sorry for the bad image resolution) :

No artifacts on windows [No artifacts on windows]

I know about the existence of Z-fighting, but wouldn't that issue persist on Windows as well? I am using a 16 bit depth buffer resolution on Android (which seems to be the maximum here).

Is there something I could be missing or doing wrong?

Thank you!

\$\endgroup\$

1 Answer 1

1
\$\begingroup\$

Well, I was wrong, the maximum depth precision is 24 bits, and setting it this way completely eliminated the problem.

Before, on Android, my EGL configurations were setEGLConfigChooser(8, 8, 8, 0, 16, 0).

With setEGLConfigChooser(8, 8, 8, 0, 24, 0) everything works great.

\$\endgroup\$

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.