Offline GPU Path Tracer
Progressive spectral Monte Carlo GPU path tracer in Slang and C++ using Vulkan
This project is a GPU-accelerated offline path tracer combining modern acceleration structures, efficient instancing, and progressive rendering techniques. The renderer supports a mix of primitive types and large-scale repeated geometry while targeting high performance on the GPU.
The full project write-up, source code, and latest updates are available on GitHub.
Project features
- Sphere primitives
- Triangle primitives with OBJ loading
- Gaussian splat primitives with PLY loading
- BSDF material support including IOR and metallic parameters
- Mesh lights
- CPU BVH construction and GPU traversal
- Progressive path tracing with temporal accumulation
- Transforms (location, rotation, and scale)
- Instancing support
- TLAS/BLAS separation
- Mixed node types in the same tree, including transform nodes, primitives, binary AABB nodes, and 8-wide KDOP nodes
- Nested instances and nested transforms
- Arbitrarily large repeated-geometry scenes with reduced memory and build-time cost
- Spectral rendering
What these features enable
The renderer is designed to handle complex scenes with repeated objects and large-scale instance hierarchies while keeping memory usage manageable. Transform and nested-instance structures allow a scene to be represented efficiently, making it possible to build scenes with many repeated groups of geometry without paying a full cost for each copy. The project also combines path tracing with temporal accumulation to refine the image progressively over time, creating high-quality images while still being responsive to real-time camera repositioning.
Implementation details
The project uses a Vulkan-based GPU pipeline with Slang for shader logic and C++ for engine structure and scene setup. Scene acceleration is organized around a hierarchy of instances and collections, and mixed node types help balance traversal efficiency and flexibility. Gaussian splat support is handled with stochastic ray tracing techniques to model transparency and alpha blending in a Monte Carlo framework.
References and related work
- Sun, Xin, et al. “Stochastic Ray Tracing of Transparent 3D Gaussians”
- Benjamin Feldman, “3D Gaussian Splatting in a Weekend”
- Arman Uguray, “Ray Tracing: GPU Edition”
- Vaidyanathan, Karthik, Sven Woop, and Carsten Benthin, “Wide BVH traversal with a short stack”
If you were looking for my CPU path tracer instead, you can find it here.