Ray Tracing (CS6620) - Project 3

Kyle Madsen




Source Code

You can find the source code here


Required Image

Here is the required image generated by my raytracer:


Download as png or ppm
Download the scene file


Debug Image

Here is the debug image generated by my raytracer:


Download as png or ppm
Download the scene file


cd

Design

Description:

I built the BVH by calculating the bounds of all the elements inside a BVH group, and extending the bounds of the parent in the process. After I know the size of the group, I start splitting the group up by alternating axes. Each group has two children objects. Then when i'm calling intersect, I see if it is in the box of the parent and if it is I check both of the children keeping track of the nearest hit just like my other group intersect method. I tried to do a lot of things to increase performace, but what i did didn't help. I would like to get back to increase the performance of this when I get some more extra time.

Difficulities:

Again I was slowed by intersection problems. I built the tree with ease early on but nothing was showing up when I would render. I though this was problem with the way I was building the tree so after some debugging I tried re-started. The same thing happended and nothing was showing up. It turns out my problem was in my triangle intersection. My epsilon was too large for one, so I made that smaller. The other problem was it wouldn't work under some cases of where the normal was facing. Things would work fine on my first assignment because it worked under that case. but in the case of the bunny, nothing would show up. After I figured all of tha tout everything was done pretty quick but I didn't get to work on the performance as much as I wanted.

Time Spent:


Creative Image

Lots of lights

For this scene I used the same bunny as the required image but changed the material to a dielectric. Then I added a room with mirrors on the ceiling and the back wall. All the rest of the surfaces are lambertian to give a soft surface look. Then I added a bunch of lights changing the positions around a bit to make it look weird. You can see where the point lights are by looking at the light points by the ceiling. The light points actually give you an idea where the back and top walls collide.


Download as png or ppm
Download scene file