Contents /
Previous /
Next
Why Vertex Arrays
Drawbacks with the traditional method:
gl.glBegin( ..);
gl.glVertex3f( .. );
gl.glVertex3f( .. );
gl.glVertex3f( .. );
.
.
} gl.glEnd();
-
Requires many function calls to render geometric primitives.
-
Redundant processing of vertices that are shared between adjacent polygons.
Solution:
Vertex array routines that allow you to specify and access a lot of vertex-related data
with few function calls.
Also, using vertex arrays and index arrays may allow non-redundant
processing of shared vertices.