CS40 Lab 5: Texture mapping

Due 11:59pm Monday 28 February 2011

You may work with one partner on this assignment. In this lab you will extend your lab 04 to apply textures to the planets and axial rotation.

Data
The file solarData.txt in your labs/05 folder contains some basic info about our solar system (and Pluto, which has recently been disqualified). The data file has been modified to include axial rotation period in days and axial tilt in degrees. Texture maps appear in /usr/local/doc/*.png. These files came from The planet pixel emporium
Basic Requirements
Modify your planet class to store texture and tilt information. Apply textures to all the planets and spin the planet about its axis according to the time of day. You will likely want a way to speed up and slow down time so you can observe spinning and orbiting as desired.
Getting Started
Rather than encoding the full path for the texture maps, I suggest making a symlink in your build directory. ln -s /usr/local/doc/ data. Then you can refer to the image files as data/planet.png in your test code.
Submit
Once you are satisfied with your programs, hand them in by typing handin40 at the unix prompt. You may run handin40 as many times as you like, and only the most recent submission will be recorded. This is useful if you realize after handing in some programs that you'd like to make a few more changes to them.