The Rendering Program's
Architecture Webpage

The hyperspace tunnel rendering program was designed as a C program that was compiled as a native Mac OS X carbon console application using Metrowerk's Code Warrior C++ compiler. I have decided to not include the actual source code for the program on this webpage for several reasons. First, I'm not at all sure I want to give away 48 hours of work! Plus, the vast majority of people probably wouldn't understand the actual code anyway. But I will go through the code in pseudo code form so you can get a complete idea how I accomplished the task. To fully understand what I'm going to explain below, it would be very helpful for you to be familiar with a programming language, preferably C. You should also be familiar with trigonometry and computer graphics.

The highest level program pseudo code to create an animation sequence is listed below:

// Start of main --------------------------------------------

Allocate memory to hold the texture map and Viewport Accumulator Array, i.e. the VAA.
Load the texture map and the Color Lookup Table, i.e. the CLUT, from disk files.
Initialize variables associated with determining current position of texture map in the tunnel.
Initialize the Viewport Counter Array, i.e. the VCA.  The VCA is used with the VAA.
Create the hyperspace tunnel.

for (each frame of animation that we are supposed to generate)
   {
   if (we are creating a motion blurred image then)
      Spin and translate the hyperspace tunnel and add motion blur to the image.
   else
      Only spin and translate the hyperspace tunnel.

   Create the filename for the next frame of output animation.
   Attempt to open a RAW format disk file with the just formed filename.

   for (each scanline of the hyperspace tunnel output image)
      {
      Retrieve the next true color hyperspace tunnel output file scanline.
      Write this color scanline to the output file.
      }

   Close this output file.
   }

Free all the dynamically allocated memory.
The program has ended.

// End of main --------------------------------------------

Last Updated: May 3, 2002
HTML URL: http://geocities.datacellar.net/~special_effect/ht_program_architecture.html
E-Mail: special_effect.geo@yahoo.com or click here
1