Real-Time PathTracer
A physically based renderer that simulates global illumination, reflections and refractions on the GPU. Written in Rust on WGPU, so it runs on Vulkan, Metal, DirectX 12 and the web from one codebase.
Overview
This is the GPU successor to my CPU ray tracer. The goal is interactive frame rates with progressive refinement: the image converges while the camera is still and resets as soon as it moves.
The preview on this page is a small WebGL2 path tracer written for this site. It uses the same algorithm on a much simpler scene, so you can watch an image converge sample by sample.
What I built
- 01 Unidirectional Monte Carlo path tracing with progressive accumulation.
- 02 Physically based materials: diffuse, metallic and dielectric (glass) with Fresnel.
- 03 Global illumination, soft shadows, reflections and refractions from a single integrator.
- 04 Cross-platform GPU pipeline through WGPU and WGSL shaders.