CSE168 Final Project
For my final project, I chose to render a car, specifically a Lamborghini Murcielago.
I found the model when I was browsing turbosquid, and it was free and very detailed so I decided it would be a good model to attempt to render.
The Car Model
I broke up the car model itself into individual smaller pieces using 3ds max. I exported each of the pieces of the car into OBJ files which would be assigned specific material properties
Depth of Field
To simulate the depth of field effect, I chose to have the focus plane on the middle of the car. I then took several random samples at each pixel, moving the camera but keeping its focus on the focal point. This way, most of the car is in focus and its farther and closer parts are slightly blurred. The cacti behind the car are also blurred more because they are farther away.
To get rid of any aliasing effects, as well as smooth out some of the blur caused by the depth-of-field effect, I anti-aliased the final image with supersampling. I chose to go with strict 2x2 samples per pixel instead of doing adaptive sampling here. If I had the time, I would have implemented adaptive sampling here to increase rendered speed and image quality at the same time.
HDR Environment Map
I found a light probe HDR/PFM map that better suited my scene and added it also. This map provides a very nice background and also reflects off the reflective surfaces in the scene. Anything that is reflective will reflect the environment map also. I attempted to also apply Bilinear Texture Filtering on the environment map to produce a clearer texture map. This did lower the pixelation a bit and produced a slightly cleaner map. This was a little weird to implement because it isn't a regular square/rectangular texture.
Because access to the environment map was with a vector, I used rotations on that vector to grab neighboring texels for the filtering process. With a lightprobe map, 360 degress is represented horizontally across the map and 360 degrees is represented vertically. So, an estimation for pixel steps could be (360 degrees/pixel width) and (360 degrees/pixel height) respectively for the width and height of the light probe map. I used this to access the necessary texels to filter the background.
Without DOF, but with Antialiasing
I actually like this image a lot because the anti-aliasing really cleaned up some artifacts with the metallic rims to really give them a realistic look. And you can also very clearly see the streaking reflection of the environment on the side of the car's red body.
Pre-Final Image(shown at rendering competition)
Real Final Image
Some Notes about the final image:
32 Depth of field samples and 2x2 Antialiasing done at every pixel
Hard shadow rays were cast onto the ground(no visible shadows casted by objects onto other objects).
The depth of field focus plane is through the middle of the car, as the nearest and farthest parts of the car are out of focus. The cacti in the background really express the use of depth of field in this image, as each progressively farther cactus is blurred slightly more.
Hard shadows were added in to give a last realistic touch to the final image. I didn't use area lights because the depth of field and anti-aliasing were enough to soften up the shadows and also computing soft-shadows with depth of field and anti-aliasing makes rendering take unbearably longer, given I only had 2-3 days to complete this project because of CSE 125 (final demo the Friday before).
I'm happy with my final image, but I'm not happy that I couldn't implement more effects than I did. If I could have added more, I would have prolly also done photon mapping or path tracting with the interior of the car. Maybe next time when I don't have CSE125 to finish up the week before :). Overall, I've learned a lot, and I will continue to fiddle with the ray tracer I was able to make in this class.