An Efficient Representation for Irradiance Environment Maps Ravi

  • Slides: 27
Download presentation
An Efficient Representation for Irradiance Environment Maps Ravi Ramamoorthi Pat Hanrahan Stanford University SIGGRAPH

An Efficient Representation for Irradiance Environment Maps Ravi Ramamoorthi Pat Hanrahan Stanford University SIGGRAPH 2001

Irradiance Environment Maps R Incident Radiance (Illumination Environment Map) N Irradiance Environment Map

Irradiance Environment Maps R Incident Radiance (Illumination Environment Map) N Irradiance Environment Map

Assumptions • Diffuse surfaces • Distant illumination • No shadowing, interreflection Hence, Irradiance is

Assumptions • Diffuse surfaces • Distant illumination • No shadowing, interreflection Hence, Irradiance is a function of surface normal

Diffuse Reflection Reflectance (albedo/texture) Radiosity (image intensity) = Irradiance (incoming light) × quake light

Diffuse Reflection Reflectance (albedo/texture) Radiosity (image intensity) = Irradiance (incoming light) × quake light map

Computing Irradiance • Classically, hemispherical integral for each pixel Incident Radiance • Lambertian surface

Computing Irradiance • Classically, hemispherical integral for each pixel Incident Radiance • Lambertian surface is like low pass filter • Frequency-space analysis Irradiance

Spherical Harmonics 0 1 2. . . -2 -1 0 1 2

Spherical Harmonics 0 1 2. . . -2 -1 0 1 2

Spherical Harmonic Expansion Expand lighting (L), irradiance (E) in basis functions =. 67 +.

Spherical Harmonic Expansion Expand lighting (L), irradiance (E) in basis functions =. 67 +. 36 + …

Analytic Irradiance Formula Lambertian surface acts like low-pass filter 0 0 1 2

Analytic Irradiance Formula Lambertian surface acts like low-pass filter 0 0 1 2

9 Parameter Approximation Order 0 1 term Exact image RMS error = 25 %

9 Parameter Approximation Order 0 1 term Exact image RMS error = 25 % 0 1 2 -2 -1 0 1 2

9 Parameter Approximation Order 1 4 terms Exact image RMS Error = 8% 0

9 Parameter Approximation Order 1 4 terms Exact image RMS Error = 8% 0 1 2 -2 -1 0 1 2

9 Parameter Approximation Order 2 9 terms Exact image RMS Error = 1% For

9 Parameter Approximation Order 2 9 terms Exact image RMS Error = 1% For any illumination, average error < 3% [Basri Jacobs 01] 0 1 2 -2 -1 0 1 2

Computing Light Coefficients Compute 9 lighting coefficients Llm • 9 numbers instead of integrals

Computing Light Coefficients Compute 9 lighting coefficients Llm • 9 numbers instead of integrals for every pixel • Lighting coefficients are moments of lighting • Weighted sum of pixels in the environment map

Comparison Incident illumination 300 x 300 Irradiance map Texture: 256 x 256 Hemispherical Integration

Comparison Incident illumination 300 x 300 Irradiance map Texture: 256 x 256 Hemispherical Integration 2 Hrs Irradiance map Texture: 256 x 256 Spherical Harmonic Coefficients 1 sec

Rendering • We have found the SH coefficients for irradiance which is a spherical

Rendering • We have found the SH coefficients for irradiance which is a spherical function. • Given a spherical coordinate, we want to calculate the corresponding irradiance quickly.

Rendering Irradiance approximated by quadratic polynomial 4 x 4 matrix (depends linearly on coefficients

Rendering Irradiance approximated by quadratic polynomial 4 x 4 matrix (depends linearly on coefficients Llm) Surface Normal vector column 4 -vector

Hardware Implementation Simple procedural rendering method (no textures) • Requires only matrix-vector multiply and

Hardware Implementation Simple procedural rendering method (no textures) • Requires only matrix-vector multiply and dot-product • In software or NVIDIA vertex programming hardware

Complex Geometry Assume no shadowing: Simply use surface normal

Complex Geometry Assume no shadowing: Simply use surface normal

Lighting Design Final image sum of 3 D basis functions scaled by Llm Alter

Lighting Design Final image sum of 3 D basis functions scaled by Llm Alter appearance by changing weights of basis functions

Results

Results

Summary Theory • • Analytic formula for irradiance Frequency-space: Spherical Harmonics To order 2,

Summary Theory • • Analytic formula for irradiance Frequency-space: Spherical Harmonics To order 2, constant, linear, quadratic polynomials 9 coefficients (up to order 2) suffice Practical Applications • Efficient computation of irradiance • Simple procedural rendering • New representation, many applications

Precomputed Radiance Transfer for Real-Time Rendering in Dynamic, Low-Frequency Lighting Environments Peter-Pike Sloan, Microsoft

Precomputed Radiance Transfer for Real-Time Rendering in Dynamic, Low-Frequency Lighting Environments Peter-Pike Sloan, Microsoft Research Jan Kautz, MPI Informatik John Snyder, Microsoft Research SIGGRAPH 2002

Basic idea Preprocess for alli

Basic idea Preprocess for alli

Precomputation Use 25 bases. . . Basis 16 Basis 17 Basis 18. . .

Precomputation Use 25 bases. . . Basis 16 Basis 17 Basis 18. . . illuminate result

Diffuse No Shadows/Inter Shadows+Inter

Diffuse No Shadows/Inter Shadows+Inter

Glossy No Shadows/Inter Shadows+Inter • Glossy object, 50 K mesh • Runs at 3.

Glossy No Shadows/Inter Shadows+Inter • Glossy object, 50 K mesh • Runs at 3. 6/16/125 fps on 2. 2 Ghz P 4, ATI Radeon 8500

Arbitrary BRDF Anisotropic BRDFs Other BRDFs Spatially Varying

Arbitrary BRDF Anisotropic BRDFs Other BRDFs Spatially Varying

Volumes • Diffuse volume: 32 x 32 grid • Runs at 40 fps on

Volumes • Diffuse volume: 32 x 32 grid • Runs at 40 fps on 2. 2 Ghz P 4, ATI 8500 • Here: dynamic lighting