The Rendering Equation
What is Global Illumination?
- Approximation of Physically Based Illumination
- Attempts to compute the light transfer between all objects in a scene, including direct and indirect illumination
- Types of light interactions between objects
- Diffuse to Diffuse
- Specular to Diffuse
- Diffuse to Specular
- Specular to Specular
- Local Illumination Model : L (D|S) E
- Each path is terminated by the eye and a light
E - the eye
L - the light - Each bounce involves an interaction with a surface
D - diffuse reflection or transmission
S - specular reflection or refraction
- Each path is terminated by the eye and a light
The Rendering Equation
- General formulation of the global illumination problem: it describes how the
radiance from surface x reflects from the surface x':
Lightout = Lightemitted + Lightin
or - L is the radiance from a point on a surface in a given direction ω
- E is the emitted radiance from a point: E is non-zero only if x' is emissive
- V is the visibility term: 1 when surfaces are unobstructed along the direction ω, 0 otherwise
- G is the geometry term, depends on geometric relationship between two surfaces x and x'
- S represents all points on all surfaces in the scene
- Algebriac way of formulating conservation of light energy
- Physically, a measure of the amount light in the scene, i.e., determine what sensors, if placed in the scene, would sense if they respond to incident radiance. Then "amount of light" should mean something like "how many photons" but no photons go through a single point. Instead, represent photon density.
- Notes
- it is linear: it is composed only of multiplications and additions
- it has spatial homogeneity: it is the same in all positions and orientations
- it is recursive!
- this means a wide range of factorings and rearrangements are possible and approximation is needed
Approximation Required
- Typically cannot solve integral directly for discrete image
- Practically, a "sampled" representation of
such a function, i.e., a function from a finite grid to colors. At each
point of the grid, the function should indicate the amount of light
coming through that point towards your eye.
- Current Assumptions: light is emitted, scattered, and
absorbed at surface (i.e., between surfaces, it travels in straight lines).
- No participating media (clouds, smoke)
- No varying index of refraction (heated air or water)
- No inter-light-beam effects (lasers)
- No wave- or quantum-level effects (diffraction, self-shadows, etc.)
Views of the Rendering Equation
Graphics pipeline (OpenGL): LE
- Computes only direct lighting based on angle of incidence between light and geometry
- Approximates geometry through small polygons, each object is processed one at a time
- Mostly view independent
Ray Tracing: L S* E
- View of rendering equation: approximate by sampling along rays where the integrand is likely to be large
- Takes place in image space: try to guess where the photons that hit the screen come from
- Algorithm: cast a ray from camera through each pixel in final image into scene, see what it hits and hits and ...
- View-dependent: must be recalculated when camera is moved
- Provides improved illumination model, but does not handle
- Specular-to-diffuse
- Diffuse-to-diffuse
- Diffuse-to-specular
- Caustics (focused light)
Radiosity: L D* E
- View of rendering equation: approximate by iterating over diffuse scattering of radience
- Takes place in object space: try to guess how much light is emitted from each object in scene
- Algorithm: divide objects into patches, approximate light gathered and reflected from patch, refine and refine and ...
- View independent
Global Illumination Algorithms
- View any surface as light source for, reflect light onto, or shadow any surface in the scene
- Solve rendering equation using numerical integration:
- using Monte Carlo path tracing with Russian Roulette for path termination
- Combine Ray Tracing and Radiosity
- pass 1: enhanced radiosity to account for diffuse to diffuse and specular to diffuse
- pass 2: diffuse to specular and specular to specular using enhanced ray tracing
- why two passes?
- view-independent specularity and view-dependent diffuse computations are too expensive
- view-independent diffuse computation followed by view-dependent specular computation is doable
- Set scalable approach to Global Illumination with levels:
- global ambience: just add sky ambience
- global illumination: also add soft GI shadows
- global radiosity: also add color bleeding
- note, high quality versions of second and third levels cannot be done in real time
- Voxel-based illumination
- compose scene of discrete voxels, encoded in an octree data structure, to model both surfaces and space
- use voxel cone tracing process to gather indirect lighting from the voxel grid
- "the emissive voxel view is where the magic happens" - illuminated voxels act as sources of light, generating indirect lighting
Remaining Hard Problems
- Reflective Diffraction Effects
- thin films
- feathers of a blue jay, butterflies
- oil on water
- CDs
- Anisotropy
- hair
- brushed metals
- strands pulled materials
- satin and velvet cloths
References
- Notes on Ray Tracing
- Notes on Radiosity
- Radiosity Form Factor Applet
- Radiosity Shooting vs Gathering Applet
- The Rendering Equation by Jim Kajiya
- Physically Based Shading Course at SIGGRAPH
- Global Illumination in Minecraft
- V-Ray, commercial "modern" renderer that supports a variety of geometry models