CS 686 PROJECT 4 Due Date: Noon Tuesday 12/13/2005 This project affords students the opportunity to apply the knowledge gained in this course on programming SVGA devices, to create a ray-traced image of a mathematically defined object in 3-dimensional space. PROJECT STATEMENT Select one of the quadratic equations in three variables x, y, z (as shown on the back this page) describing a (non-degenerate) curved surface in space, and choose a position in space from which a viewer can see this object, illuminated by at least two distinct point-sources of light. Use your knowledge of linear algebra, calculus, and SVGA graphics programming to create a C++ program that will employ ray-tracing principles to render the image of your curved surface in a photorealistic manner. (Do NOT use a sphere, because we have already done that example in class; your curved surface should be either a paraboloid, an ellipsoid, or a hyperboloid.) You may, at your option, include one or more additional objects such as a planar surface, a background curtain or other decorative effects, if doing so will produce a more interesting scene (and will not detract from the main emphasis on your selected quadratic surface). Additional credit is awarded for inclusion of features that go beyond the basic assignment. NOTE: It is probable that you will need to employ rules from calculus for computing the normal-vector to a curved surface at any given point (i.e., the so-called "partial derivatives" with respect to x, y, and z). WHAT TO SUBIT You will need to give your Instructor a printout of the C++ program source-code that you write--along with a printed copy of a 'README' file which explains the objects in your ray-traced scene (their locations and your quadric surface's equation), along with any other remarks a reader would need in order to easily understand your program-code. These paper printouts should be delivered to the Instructor's mailbox in HRN-208 (as usual) by the project deadline, and should show YOUR NAME on each. Also you should copy any computer files you create to your /submit directory, as usual, so that the Instructor can re-compile and execute your program for the purpose of testing and grading it. (Failure to submit essential pieces of this project, binaries or hardcopies, will result in a zero on this assignment.) You are allowed to discuss this project with the course Instructor, or with aother student who is taking this course; but you must write the actual code you submit yourself, to be sure you understand its ideas and can explain any algorithms you use to your Instructor when questioned. ________________________________________________________________________ Allan B. Cruse University of San Francisco Fall 2005