MIT
Department of Ocean Engineering

13.016 Introduction to Geometric Modeling and Computation

Spring 1997


Problem Set 3 Hints


February 20

The demo program /mit/13.016/graphics/demo1-xform.c looks very daunting; fortunately, you can ignore most of it. The main() function should look familiar to last week's program. For this problem set, the only function that you will need to modify is the display callback function display().

This function does five things:

  1. Defines the projection and viewing transformations.
  2. Draws the global XYZ axes.
  3. Performs any modeling transformations.
  4. Draws a geometric model (here, a unit cube centered at the origin).
  5. Displays the transformation values as character strings.

You will only need to modify Step 4, which is marked in the source code with a descriptive comment.