I have a function:
void drawBox(vector3 a,vector3 b)
{
glBegin(GL_LINES);
...
glVertex3f(a[0],a[1],a[2]);
...
glEnd(GL_LINES);
}
Now I need to do it in opengl-es which need to use vertex pointer right? but the position of vector a and vector b, changes a lot,such as if it represent as a bounding box, I’ve searched this page http://maniacdev.com/2009/05/porting-opengl-glvertex-code-to-iphone-opengl-es/ , it uses a const GLfloat which is not what I need right now,so my question is how to write this function in opengl-es way?
1 Answer