Porting Triangles

You can draw three types of triangles in OpenGL: separate triangles, triangle strips, and triangle fans.

OpenGL has no equivalent for the IRIS GL swaptmesh function. You can achieve the same effect using a combination of triangles, triangle strips, and triangle fans.

The following table lists the IRIS GL functions for drawing triangles and their equivalent OpenGL functions.

IRIS GL Function Equivalent glBegin Parameter Meaning
GL_TRIANGLES Triples of vertices interpreted as triangles.
bgntmesh
endtmesh
GL_TRIANGLE_STRIP Linked strips of triangles.
GL_TRIANGLE_FAN Linked fans of triangles.