

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


Due: Before class on Tuesday, February 6th
Goal: Improve your ray tracer by implementing a bounding volume hierarchy and a non-pinhole camera.
Problem 1: (30 points) Implement a bounding volume hierarchy for your ray tracer. For this exercise, you should select your split plane by dividing the longest axis so that each child node has half as many primitives as the parent.
Optimization note: To maintain the performance of your BVH throughout the rest of the semester, make sure you do not dynamically allocate memory while traversing the tree. Any dynamic memory allocation should occur only during the build process.
Problem 2: (20 points) Implement a thin-lens camera, as described on page 68 of Realistic Ray Tracing. In order to do this, you must write a new camera class ThinLensCamera. For good results, you will need to use multiple sam- ples per pixel. To improve the modularity of the code, I suggest renaming the current Camera class to PinholeCamera and writing a base class Camera that both PinholeCamera and ThinLensCamera inherit from.
Note: Please create a web page to demonstrate the results of this (and future) assignments, and send me a link to this web page. Also tell me if you have problems with me linking this page from the class web page.