A Path Tracer
One bounce at a time, from a single ray to a million triangles.
The path tracer starts as a question — what does this ray hit? — and ends as a courtyard rendered at ten million triangles, lit by an HDR sky and a hundred small lamps. Each chapter breaks an assumption the previous one was hiding behind.
Geometry comes first: rays, primitives, the bounding volume hierarchy that makes a hundred thousand intersections cheap. Then light, introduced stochastically — a pixel becomes the answer to an integral, solved by Monte Carlo with explicit connections to the sources. Surfaces stop being flat at the scale that matters; the BRDF grows three terms and a sampler that follows the lobe. Light is allowed to pass through a surface, refract, and emerge tinted by what it travelled through. The hand-placed sphere light is replaced by a sky and by every emissive triangle in the scene — and the scene itself becomes San Miguel.
The rendering equation does not change across the five. What grows around it is the renderer's grasp of the scene — surface by surface, light by light, scale by scale — and each widening unlocks an image the previous chapter could not produce.
CHAPTERS
- 01
First Hit
— Ray CastingWhere a renderer is mostly a machine for finding numbers — and the gap between mathematically correct and computationally tractable becomes visible.
Ray–primitive intersection BVH Möller–Trumbore GLM2026 · FEB · 04→ - 02
Light Finds Its Way
— Path TracingWhere the renderer stops asking what each ray hits and starts asking what the light is doing after it gets there.
Monte Carlo integration Cosine-weighted sampling Russian Roulette Next-event estimation2026 · MAR · 01→ - 03
Mirrors
— Microfacet BRDFsWhere surfaces stop being flat at the scale of light, and the BRDF starts negotiating between what diffuses and what reflects.
Cook-Torrance Phong NDF Smith G Schlick Fresnel2026 · MAR · 14→ - 04
Through Glass
— TransmissionWhere light is allowed to enter a surface, bend through it, and emerge tinted by what it travelled through.
Snell refraction Microfacet BTDF Total Internal Reflection Beer's Law2026 · MAR · 29→ - 05
The Room Itself
— Image-Based Lighting & ScaleWhere the renderer leaves the test scene behind and walks into a courtyard of ten million triangles, lit by a sky and the lamps in the room.
HDR Environment Map Importance-sampled CDF Area Light from emissive geometry Binary scene cache2026 · APR · 14→