NYGhost
2004.11.15, 04:53 PM
Hello again!
I know glDrawElements() allows me to specify vertex indexes to be rendered.
Enabling the GL_TEXTURE_COORD_ARRAY is like extending the definition of the a point to include texture coords.
the question is:
Is there a way to specify UV indexes to use when rendering the primitives?
the reason for my question is that my geometry may have different number of vertex, UV, and normals so glDrawElements() would render incorrectly.
the way I draw textured triangle is by using 6 indexes (3,3) three for each vertex array.
I know by switching to vertex arrays would eliminate lots of overhead, but,
Is it worth it?
If there's no way to specify those UV indexes I would have to preprocess the geometry, and add the missing elements. :(
I know glDrawElements() allows me to specify vertex indexes to be rendered.
Enabling the GL_TEXTURE_COORD_ARRAY is like extending the definition of the a point to include texture coords.
the question is:
Is there a way to specify UV indexes to use when rendering the primitives?
the reason for my question is that my geometry may have different number of vertex, UV, and normals so glDrawElements() would render incorrectly.
the way I draw textured triangle is by using 6 indexes (3,3) three for each vertex array.
I know by switching to vertex arrays would eliminate lots of overhead, but,
Is it worth it?
If there's no way to specify those UV indexes I would have to preprocess the geometry, and add the missing elements. :(