cube.c
Tom Kelliher, CS 320
Apr. 24, 2000
Read 4.8,9.
Pong lab day.
- Study of cube.c.
Object transformations: transformation concatenations, OpenGL
implementation.
Assume the x- and y-axes have their usual orientation and that the +z-axis
points towards you. The questions (A -- Aaron, R -- Rachel, S -- Sze-Ling):
- (R)
Draw the cube in 3-dimensional space, labeling (0-7) the vertices.
- (S)
What are the indices of the vertices making up the front and back (as seen
from the +z axis) faces of the cube?
- (A)
Modify the program so that only the (0,4,7,3) and (1,2,6,5) cube faces are
rendered. Run the program with and without depth-buffering enabled.
Explain the results.
- (R)
The edges of the cube don't appear to be parallel. Why?
- (S)
Explain polygon().
- (A)
Explain the cube ``data structure.''
Additional questions:
- How could the cube data structure be extended to handle arbitrary
objects?
- Why does the cube's back face rotate in the opposite direction
in comparison to the cube's front face?
- How do the colors vary? Why do they vary? How is the effect
achieved?
Thomas P. Kelliher
Mon Apr 24 08:38:12 EDT 2000
Tom Kelliher