






Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!







Adapted from Edward Angel, UNM Angel: Interactive Computer Graphics 3E © Addison-Wesley 2002
Angel: Interactive Computer Graphics 3E © Addison-Wesley 2002^3
Angel: Interactive Computer Graphics 3E © Addison-Wesley 2002^7
GLUT GLU GL
GLX, AGL or WGL X, Win32, Mac O/S
software and/or hardware
application program
widget or similarOpenGL Motif
Angel: Interactive Computer Graphics 3E © Addison-Wesley 2002^9
Immediate Mode
Display List
Polynomial Evaluator
Per Vertex Operations &Primitive Assembly
Rasterization Per FragmentOperations
MemoryTexture
CPU
Pixel Operations
FrameBuffer
Geometric pipeline
curves & surfaces
Angel: Interactive Computer Graphics 3E © Addison-Wesley 2002^13
glVertex3f(x,y,z)
belongs to GL library
function name
x,y,z are floats
glVertex3fv(p) p is a pointer to an array
Angel: Interactive Computer Graphics 3E © Addison-Wesley 2002^15
#include <glut.h> void mydisplay(){ glClear(GL_COLOR_BUFFER_BIT); glBegin(GL_POLYGON); glVertex2f(-0.5, -0.5); glVertex2f(-0.5, 0.5); glVertex2f(0.5, 0.5); glVertex2f(0.5, -0.5); glEnd(); glFlush(); } int main(int argc, char argv){ glutCreateWindow("simple"); glutDisplayFunc(mydisplay); glutMainLoop(); }**