Example Program: box.cc
The function call glColor4fv( red ) refers to the first OpenGL function we've seen. Notice that it begins with gl just like all the GLUT functions we saw began with glut.
The name of the function ends with 4fv:
- the 4 indicates that the parameter passed contains four elements,
- the f indicates that the parameters are floating point (as opposed to integer) values,
- the v indicates that the parameter is a vector (array), rather than four separate parameters.