vertex array
Hi everyone,
I would like to have any information about vertex array,
I''ve searched the net for some tutorial, but everything I''ve got is a spinning cube...
So from what I''ve understood, vertex array need two array, one for the vertex themselves, and another one for face indices.
So my question is how can I compute this indices array?
If someone have an answer or can point me on a tutorial.
Regards,
Ramsay_fr
0 1 +--------+ /| /|3 / | 2 / | +--------+ | | 4| | 5| | +-----|--+ | / | /7|/ 6|/ +--------*
vertex[8] will be the xyz coords in space of the cube vertices
if you will draw the cube with glDrawArrays your indicies array will be {0,1,2,3, 1,5,6,2, 2,6,7,3, 6,5,4,7, 0,3,7,3, 0,4,5,1}
with argument GL_QUADS, and 6*4 elements
6 quads each has 4 vertices
I think nvidia has some tutorial with compiled vertex array
[edited by - cifko on January 23, 2003 11:18:01 PM]
[edited by - cifko on January 23, 2003 11:18:15 PM]
[edited by - cifko on January 23, 2003 11:18:24 PM]
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement