I just spent way too much time finding and fixing a shading problem and now I have a question. Does the GL_TRIANGLE_STRIP have serious draw backs? When I first read about them I thought they seemed like a great idea; save a lot of space/time by using less vertices.
Well, the GL_TRIANGLE_STRIP implies the triangles will be in a different order; which is the problem. All of the OPENGL books are using GL_TRIANGLES in their shaders I assume now to avoid the difficulty with the GL_TRIANGLE_STRIP in terms of consistency. Specifically, a
GL_TRIANGLE_STRIP has the following order: v0v1v2, v0v2v3, …, v0v(n-2)v(n-1). GL_TRIANGLES have the following order: v0v1v2, v3v4v5, …, v0(n-3)v(n-2)v(n-1).
This inconsistency causes issues in shaders while the consistency of TRIANGLES lends itself real well to fast programmable shader solutions. Of course, we could unravel the GL_TRIANGLE_STRIP inconsistencies in the shaders but doesn’t that drawback make GL_TRIANGLES a better solution than GL_TRIANGLE_STRIP?
I assume most will tell me it depends on the condition. However, since most of the books rely on GL_TRIANGLES and not GL_TRIANGLE_STRIP, does that mean they the preferred primitive?
Any help is appreciated…