An overview of OpenGL
- A platform independent api
- Designed to work well with both hardware and software
- Standard, open, widely implemented.
- A set of several hundred procedures and functions
- (as well as defined constants.)
- GLU - the OpenGL Utility Library provides additional
support functions for modeling.
- gluOrtho2D allows you to define a 2D viewing frame
and is a utility function that uses glOrtho
- gluOrtho2D( left, right, bottom, top)
- sets up a two-D viewing region.
- glOrtho(left, right, bottom, top, near, far)
- glOrtho(left, right, bottom, top, -1, 1)
- Specifies the clipping planes for a 3d view volume.
- See man pages for each.
- GLUT - OpenGL Utility Toolkit, a system independent toolkit for
writing OpenGL programs.
- This is really what is supporting our event driven programs for now
- It provides interface routines, for example keypress events
- It also provides some nice routines for creating shapes
glutSolidSphere(radius, slices, stacks);
- Font support as well.
- OpenGL is also thought of as a State Machine
- You can turn on a light, and it is on until turned off.
- You tell it the next set of points form a polygon.
- Finally Open Gl is an implementation of the graphics pipeline.
-
- Vertex data is as we have been discussing
- Pixel data is data from a frame buffer, or image, or ...
- In a display list data is sent to the display processor once, and does not need to be resent each time the screen is redrawn.
- Think of this as static local variables in a procedure
- Use of these can speed up image generation, especially when
the network is involved.
- Evaluators derive actual verticies from given verticies.
(Splines, NURBS, ...)
- Per-Vertex operations turn vertex data into the surfaces.
- Primitive assembly - clipping and other such operations
- Pixel operations - pixels are placed in the proper format, and
perhaps undergo geometric transformations
- Rasterization as before,
- per-Fragment operations - texture mapping, fog, depth buffer, ...