Red Book, Redbooks, Little Red Book or Big Red Book may refer to: Contents. 1 Political part of the Rainbow Series by the National Computer Security Center; The Red Book, alternate name for the 8th edition of the OpenGL Programming. Welcome to the website for the OpenGL Programming Guide (the “Red Book”). The latest release — the ninth edition — brings the most comprehensive. Today’s OpenGL software interface enables programmers to produce extraordinarily “The most recent Red Book parallels the grand tradition of OpenGL;.

Author: Mikasida Akinoktilar
Country: Chad
Language: English (Spanish)
Genre: Automotive
Published (Last): 1 November 2006
Pages: 201
PDF File Size: 5.66 Mb
ePub File Size: 17.33 Mb
ISBN: 966-9-96810-470-7
Downloads: 40889
Price: Free* [*Free Regsitration Required]
Uploader: Moogudal

Advanced rendering and later extensions are not covered in these examples. This program shows how to draw anti-aliased lines in color index mode.

The Red Book

It draws two diagonal lines to form an X; when ‘r’ is typed in the window, the lines glproggamming rotated in opposite directions. This program shows how to draw anti-aliased lines. Use the accumulation buffer to do full-scene antialiasing on a scene with perspective projection, using the special routines accFrustum and accPerspective. This program draws several overlapping filled polygons to demonstrate the effect order has on alpha blending results.

Use the ‘t’ key to toggle the order of drawing polygons. This program demonstrates how to intermix opaque and alpha blended polygons in the same scene, by using glDepthMask.

Press the ‘a’ key to animate moving the transparent object through the opaque object. Press the ‘r’ key to reset the scene. This program renders a lighted, filled Bezier surface, using two-dimensional evaluators. This program texture maps a checkerboard image onto two rectangles. This program clamps the texture, if the texture coordinates fall outside 0.

After initialization, the program will be in ColorMaterial mode. This program demonstrates a single modeling transformation, glScalef and a single viewing transformation, gluLookAt. A wireframe box is rendered. This program demonstrates use of the accumulation buffer to create an out-of-focus depth-of-field effect.

The teapots are drawn several times into the accumulation buffer.

The viewing volume is jittered, except at the focal point, where the viewing volume is at the same position, each time. In this case, the gold teapot remains in focus. This is a simple double buffered program. Pressing the left mouse button rotates the rectangle. Pressing the middle mouse button stops the rotation. Draws the bitmapped letter F on the screen several times. This demonstrates use of glprogrammingg glBitmap call.

This program demonstrates use of OpenGL feedback. First, a lighting environment is set up and a few lines are drawn. Then feedback mode is entered, and the same lines are drawn. The results in the feedback buffer are glprorgamming. This program draws 5 red teapots, each at a different z distance from the eye, in different types of fog.


Pressing the left mouse button chooses between 3 types of fog: In this program, there is a fixed density value, as well as fixed start and end values for the linear fog. This program demonstrates fog in color index mode. Three cones are drawn at different z values in glprogrammin linear fog. There is no attempt to prevent you from drawing over the original image.

If you press the ‘r’ key, the original image and zoom factors are reset. If you press the ‘z’ or ‘Z’ keys, you change the zoom factors. This program demonstrates the use of the OpenGL obok model. A sphere is drawn using a glprogrammjng material characteristic.

A single light source illuminates the object. This program demonstrates how to make and execute a display list. Note that attributes, such as current color and matrix, are changed. This program demonstrates the use of the GL lighting model.

Several objects are drawn using different material characteristics.

A single light source illuminates the objects. This program demonstrates using mipmaps for texture maps. To overtly show the effect of mipmaps, each mipmap reduction level has a solidly colored, contrasting texture image. Thus, the quadrilateral which is drawn is drawn with several different colors.

This program demonstrates when to issue lighting and transformation commands to render a model with a light which is moved by a modeling transformation rotate bok translate. The light position is reset after the modeling transformation is called. The eye glporgramming does not change. The scene is then redrawn with the light in a new position. Picking is demonstrated in this program.

In rendering mode, three overlapping rectangles are drawn.

Production Guidelines

When the left mouse button is pressed, selection mode is entered with the picking matrix. Rectangles which are drawn under the cursor position are “picked. Use of multiple names and picking are demonstrated. A 3×3 grid of squares is drawn. When the left mouse button glprogeamming pressed, all squares under the cursor position have glprpgramming color changed. This program shows how to composite modeling transformations to draw translated and rotated models.

This program demonstrates polygon offset to draw a shaded polygon and its wireframe counterpart without ugly visual glprorgamming “stitching”. Quadric objects are created with some quadric properties and the callback routine to handle errors. Note that the cylinder has no top or bottom and the circle has a biok in it. This program shows how to composite modeling transformations to draw translated and rotated hierarchical models.


Objects are drawn using a grey material characteristic. This is an illustration of the selection mode and name stack, which detects whether objects which collide with a viewing volume. First, four triangles and a rectangular box representing a viewing volume are drawn drawScene routine. The green triangle and yellow triangles appear to lie within the viewing volume, but the red triangle appears to lie outside it.

Then the selection mode is entered selectObjects routine. Drawing to the screen ceases. To see if any boik occur, the four triangles are called.

OpenGL Redbook Samples

In this glprogramimng, the green triangle causes one hit with the name 1, and the yellow triangles cause one hit with the name 3. This program demonstrates smooth shading. A smooth shaded polygon is drawn in a 2-D projection. This program draws two rotated tori in a window. Blprogramming diamond in the center of bool window masks out part of the scene. Within this mask, a different bookk a sphere is drawn in a different color. This program demonstrates some characters of a stroke vector font.

The characters are represented by display lists, which are given numbers which correspond to the ASCII values of the characters. Use of glCallLists is demonstrated. This program demonstrates lots of material properties. This program demonstrates polygon tessellation.

Two tesselated objects are drawn. The first is a rectangle with a triangular hole. The second is a smooth shaded, self-intersecting star. Note the exterior rectangle is drawn with its vertices in counter-clockwise order, but its interior clockwise.

Note the combineCallback is needed for the self-intersecting star. This program demonstrates the winding rule polygon tessellation property.

Four tessellated objects are drawn, each with very different contours. When the w key is pressed, the objects are drawn with a different winding rule. This program demonstrates using glBindTexture by creating and managing two textures. This program draws a texture mapped teapot with automatically generated texture coordinates. The texture is rendered as stripes on the teapot. Pressing the ‘e’ key changes the coordinate generation to eye coordinates of the vertex.

Pressing the ‘o’ key switches it back to the object coordinates. If the s key is pressed, a texture subimage is glprogrammng to alter the original texture. If the r key is pressed, the original texture is restored. This program uses evaluators to generate a curved surface and automatically generated texture coordinates.

This program demonstrates the wrapping modes, if the texture coordinates fall outside 0.

Back to top