Well… I have about 2 pages of code of glVertex3fv(vx) where x is a #… and a list of like 10 verticies…
i want to shorten this to 3 arrays… one array has the 10 verticies… one array has the order i want them drawn in for 6 quads… and the last array has the order i want them in to draw 8 triangles…
static GLfloat vertex[10][3] = {{-1.5, 1, 1.5}, {1.5, 1, 1.5}, {1.5, 1, -1.5}, {-1.5, 1, -1.5}, {0, 2, 0}, {0, -2, 0}, {-1.5, -1, 1.5}, {1.5, -1, 1.5}, {1.5, -1, -1.5}, {-1.5, -1, -1.5}};
static GLint quadorder[6][4] = {{1,2,3,4}, {7,8,9,10}, {1,4,10,7}, {1,2,8,7}, {2,3,9,8}, {3,9,10,4}};
static GLint triorder[8][3] = {{1,2,5}, {2,3,5}, {4,3,5}, {1,5,4}, {7,8,6}, {8,9,6}, {10,9,6}, {7,6,10}};
Anyhow, is there a way for me to have it draw each triangle (based on the numbers in triorder, and all quads based on the numbers in quadorder)? could you please give me an example??
Thanks a bunch
-Impact