skip to content

Monte Carlo Direct Lighting

/ 1 min read

About

An interactive Monte Carlo path tracer that renders the same scene side-by-side using two sampling strategies: uniform hemisphere sampling and direct light sampling. Watch how explicit light sampling converges dramatically faster than uniform sampling across six different scenes — from a minimal lecture setup to multi-light neon environments. Choose your sample count (1 to 4096 spp) and see variance reduction in action.

Built as a companion visualization for Stanford CS248A: Interactive Computer Graphics.

  1. Live demo: https://visual-compute.github.io/montecarlo/
  2. Course page: https://gfxcourses.stanford.edu/cs248a/winter26