
SETUP
-----
The subroutines in draw.c use OpenGL to display the meshes.  Therefore this 
program needs to link with the related OpenGL libraries, or more specifically,
the GL, GLU, and GLAUX libraries.

For Visual C++ 6.0 users, please open the settings in Project -> Settings -> 
Link -> General category and add "GLAUX.lib GLU32.lib OpenGL32.lib" to the
string in the Object/library modules (before kerenel32.lib).

OVERVIEW OF THE DATA STRUCTURES
-------------------------------
The header files rad.h and room.h define the basic data types. 
 
The "Cornell box" scene is defined in room.c as an array of TQuad.  Each quad 
(or quadrilateral) is then divided into patches, and each patch is further
divided into elements.  

This program implemented a progressive radiosity algorithm.  During each
iteration of the program, the form factors from a shooting patch to all 
elements are computed on-the-fly and the unshot radiosity is then distributed 
from a patch to all elements.

EXERCISE
--------
1. Modify ComputeFormfactors() in ffactors.c based on the paper "A Ray Tracing
   Algorithm for Progressive Radiosity" by Wallace, Elmquist, & Haines.

   Your task is to calculated the form factors from the shooting patch to all
   elements and store them in the array formfactors[] as return values.  For 
   example, formfactors[i] contains the form factor from the shooting patch to
   element i.

2. Change the meshing level (i.e., patchLevel and elementLevel fields in
   roomPolys[] in room.c), and see how it changes the results.

FOR MORE FUN
------------
If you have time and want to have more fun, then you may extend the program by:
1. Displaying the elements as smooth-shaded polygons to remove the
   blocky look.  (See the notes in CHANGES.txt for some of my ideas.)
2. Can you put the element colors into a texture, and display each TQuad as a
   texture-mapped polygon?
3. Can you interactively display different views of the scene?

