Skip to main content
gamedev.net
🔒 Locked

Different indices for Vertex Array pointers?

Started by Kiz Jun 18, 2002 at 6:58 AM 0 replies 550+ views
Original Post
Kiz
Kiz
Does anybodh have an idea how to use different set of indices for VERTEXES, NORMALS, TEXCOORD etc. My model was looking something like nVertices = 3000 nNormals = 9000 nTexCoords = 9000 so i optimized similar normals and tex coords so now it looks something like nVertices = 3000 nNormals = 800 nTexCoords = 6500 now I want to pass this data to opengl in arrays (vertex, normal, and texcoord) so i enable client states and pass pointers the usual way but i wish to use three dfferent sets of indices. To my greatest disapointment i found out this is not possibe. The idea of reducing data was to reduce number of transformations opengl does for each glVertex3x, glTexcoord2x etc.. by passing optimized data, let opengl transform each array once and then to call indices. But what''s the point if you have vertice shared between three smoothen polygons each is having different normal... if i use same indice three times in VA every normal will be the same resulting in lost smoothing. So if i use three same vertices in array just to be able to have different normals what''s the point in VA alltogether? So let me ask again... how to use different indices array for element pointers? tnx.
Kiz

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.