Tuesday, June 4, 2019

GPU path tracer

For my bachelor's thesis I wrote an implementation of gradient-domain path tracing on the GPU. After it was done, I repurposed the path tracer into a hobby project, implementing all kinds of fun effects into it. It's written in CUDA and runs completely on the GPU. For ray-scene intersections I used Optix Prime, everything else runs on my own code. The performance ended up being fairly poor due to my inexperience with working on GPU programming. I would eventually correct those issues for my master's thesis work though.

I ended up with support for depth of field, multiple importance sampled emissive light sources and glossy materials, refractions and scenes composited from multiple objects. Here are a few images I saved over the course of that work.

 This image shows normal mapping in action. The wall geometry is just two triangles, all the detail comes from normal maps as well as diffuse and specular textures.
 Here's another image with normal maps in the crytek sponza scene. This one also features a skylight to simulate a daylight scene.
 Here's an image showing polygonal bokeh for depth of field, simulating a hexagonal aperture due to partially closed aperture blades.
A multi-object scene with glass materials and depth of field.

No comments:

Post a Comment