OpenGL

In this section:

OpenGL provides a relatively simple, platform independent, way to produce complex (possibly animated) 2 or 3-dimensional images. Lighting and perspective effects are easily introduced, although in order to achieve high performance, full ray tracing (which produces shadows and effects caused by multiply scattered light rays) is not available. The performance of OpenGL is sufficient that it is often used for 3-D animation. The following two books explain the use of OpenGL without going into platform-specific details:

OpenGL Programming Guide (Red Book)

OpenGL Reference Manual (Blue Book)

See the end of this section for further details. OpenGL is available via two DLLs that may already be installed on your PC.

This section does not present a tutorial on OpenGL nor does it describe the OpenGL API. You are advised read the official "Red Book" learning guide to OpenGL, and to visit the OpenGL web site at http://www.OpenGL.org.

Examples in the Red Book are simplified by the use of a specially designed and written auxiliary OpenGL library (called GLAUX). GLAUX provides an easy way to open a window with the OpenGL attributes that you require. However, it is limited in its use of mouse, keyboard and message handling and has the overwhelming disadvantage you cannot attach menus or buttons. Also, it only allows one window to be opened. ClearWin+ is very similar to GLAUX with regard to the ease with which OpenGL windows can be opened. However, ClearWin+ has none of the above restrictions. Nevertheless, the Red Book examples provide a convenient tutorial approach to learning how to call the OpenGL library from ClearWin+. Much of this section is devoted to discussing how to convert the the Red Book examples that use GLAUX to ClearWin+.

 

 

Basket
Empty
 
Copyright © 1999-2024 Silverfrost Limited