Math 155A - Winter 2001

Programming Assignment #3

     In this assignment, you will create a torus which can supports the following features: it can be drawn in either wire-frame mode or fill mode; it can be formed from quadrangles or from triangles; and it can be rotated under the control of the arrow keys.  A novel feature of this torus is that instead of being broken up into radial pieces, it is modeled as a single strip of polygons wrapped spirally around the torus.
    You will also build a small triangular pyramid placed in a fixed position to the side of the torus.  This will move with the torus and help you see the movement of the torus.
    This is the first of two assignments involving this torus: the next assignment (programming assignment #4) will ask you to add normal vectors, to set the material properties of the torus, and to add lights to the environment to make the torus look attractive in non-wireframe mode.

Due date: Monday, February 12 (midnight).

Main tasks: Build a program with functionality similar to the sample program in WrappedTorus.   Your program will display a wireframe or solid torus with the following functionality.

Regarding the wireframe versus filled-in modes:  in this programming assignment, the filled-in version will look very featureless and flat.  This will be improved on in the next programming assignment.

A sample programs which displays this functionality can be found as P:/Projects/WrappedTorus/WrappedTorus.exe.  

More on animation:   The rotations should be performed by rotating first around the y-axis and then around the x-axis (the glRotate commands are given in the opposite order in your OpenGL program).   Your program should support the following commands.

More details: 

Homework turn-in: You will need to prepare