| CPEN 461/661, Spring 1997 |
| OpenGL Tutorial |
The programmer is provided the following primitives for use inconstructing geometric objects.

Each geometric object is described by a set of vertices and the type ofthe primitive to be drawn. Whether and how the vertices are connectedis determined by the primitive type. For a more detailed discussion ofthese primitives, refer to With OpenGL, all geometric objects are ultimately described as anordered set of vertices. The command All calls to It is important to note that OpenGL commands are not necessarilyexecuted as soon as they are issued. It is necessary to call thecommand The following example illustrates the different results of each of theprimitive types applied to the same set of vertices. Notice that the order in which the vertices are declared is veryimportant. Also notice that some primitives, when given an incorrectnumber of vertices, will ignore any extra vertices. For example,GL_TRIANGLES only draws the triangle corresponding to vertices1, 2, and 3. Vertices 4 and 5 are ignored. glVertex2s(1, 2); glVertex3d(0.0, 0.0, 3.1415926535898); glVertex4f(1.3, 2.0, -4.2, 1.0); GLdouble vector[3] = {3.0, 10.0 2033.0}; glVertex3dv(vector);