The Rendering Equation
description
Transcript of The Rendering Equation
![Page 1: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/1.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
The Rendering Equation
Direct (local) illuminationLight directly from light sourcesNo shadows
Indirect (global) illuminationHard and soft shadowsDiffuse interreflections (radiosity)Glossy interreflections (caustics)
![Page 2: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/2.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Early Radiosity
![Page 3: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/3.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Lighting Effects
Hard Shadows Soft Shadows
Caustics Indirect Illumination
![Page 4: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/4.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Challenge
To evaluate the reflection equation the incoming radiance must be known
To evaluate the incoming radiance the reflected radiance must be known
2
( , ) ( , ) ( , )cosr r r i r i i i iH
L x f x L x dω ω ω ω θ ω= →∫
![Page 5: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/5.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
To The Rendering Equation
Questions1. How is light measured?2. How is the spatial distribution of light energy described?3. How is reflection from a surface characterized?4. What are the conditions for equilibrium flow of light in an environment?
![Page 6: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/6.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
The Grand Scheme
VolumeRendering Equation
SurfaceRendering Equation
Light and Radiometry
Radiosity Equation
Energy Balance
![Page 7: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/7.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Balance Equation
Accountability[outgoing] - [incoming] = [emitted] - [absorbed]
Macro levelThe total light energy put into the system must equal the energy leaving the system (usually, via heat).
Micro levelThe energy flowing into a small region of phase space must equal the energy flowing out.
o i e aΦ −Φ =Φ −Φ
( ) ( ) ( ) ( )e aB x E x B x E x− = −
( , ) ( , ) ( , ) ( , )o i e aL x L x L x L xω ω ω ω− = −
![Page 8: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/8.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Surface Balance Equation
[outgoing] = [emitted] + [reflected]
2
( , ) ( , ) ( , )
( , ) ( , ) ( , )coso o e o r o
e o r i o i i i iH
L x L x L x
L x f x L x d
ω ω ω
ω ω ω ω θ ω
= +
= + →∫
![Page 9: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/9.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Direction Conventions
( )r i of ω ω→
iωoω
n
( , ) ( , )i i iL x L xω ω= −
iωn
( , )i iL x ω
( , )L x ω
BRDF Surface vs. Field Radiance
oω
ω
ω
( , )L x ω
( , )o oL x ω
( , ) ( , )o oL x L xω ω=
![Page 10: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/10.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Surface Balance Equation
[outgoing] = [emitted] + [reflected] + [transmitted]
( , ) ( , ) ( , ) ( , )o o e o r o t oL x L x L x L xω ω ω ω= + +
2
( , ) ( , ) ( , )cost o t t o i t t tH
L x f x L x dω ω ω ω θ ω−
= →∫
ω
ω+
−
• >
• <
2
2
( ) ( ) 0
( ) ( ) 0o
o
H n n x
H n n x
iωiω
oωn
2H+2H−
2
( , ) ( , ) ( , ) cosr o r i o i i i iH
L x f x L x dω ω ω ω θ ω+
= →∫
BTDF
![Page 11: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/11.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Two-Point Geometry( , ) ( ) x xx x x x
x xω ω
′−′ ′= → =′−
x
x′oω
n′n
iω
( , )i x xω ω ′=
( , )o x xω ω ′=
*
*
( , )
( , )i
o
x x x
x x x
ω
ω
′=
′=
Ray Tracing*( , )x x ω
![Page 12: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/12.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Coupling Equations
Invariance of radiance
( , ) ( , )L x L xω ω′ ′=( , ) ( , )i i iL x L xω ω= −
( , ) ( , )o oL x L xω ω′ ′ ′=
x
x′oω ω′=
n′n
ω iω
![Page 13: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/13.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
The Rendering Equation
Directional form
2
*
( , ) ( , )
( , ) ( ( , ), )cose
r
H
L x L x
f x L x x d
ω ω
ω ω ω ω θ ω
= +
′ ′ ′ ′ ′→ −∫
Integrate overhemisphere ofdirections
Transport operatori.e. ray tracing
![Page 14: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/14.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
The Rendering Equation
Surface form
2
cos cos( , ') ( , )i oG x x V x xx xθ θ′′ ′
′′ ′′ ′=′′ ′−
2
( , ) ( , )
( , , ) ( , ) ( , ) ( )e
r
M
L x x L x x
f x x x L x x G x x dA x
′ ′= +
′′ ′ ′′ ′ ′′ ′ ′′ ′′∫
Integrate overall surfaces
Geometry term
1 visible( , )
0 not visibleV x x
⎧′′ ′ =⎨⎩
Visibility term
![Page 15: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/15.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
The Radiosity Equation
Assume diffuse reflection1.2.
( , ) ( ) ( ) ( )r i o r rf x f x x f xω ω ρ π→ = ⇒ =
( , ) ( ) /L x B xω π=
2
( ) ( ) ( ) ( , ) ( ) ( )e
M
B x B x x F x x B x dA xρ ′ ′ ′ ′= + ∫
( , )( , ) G x xF x xπ
′′ =
( ) ( ) ( ) ( )eB x B x x E xρ= +
![Page 16: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/16.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Integral Equations
Integral equations of the 1st kind
Integral equations of the 2nd kind
( ) ( , ) ( )f x k x x g x dx′ ′ ′=∫
( ) ( ) ( , ) ( )f x g x k x x f x dx′ ′ ′= +∫
![Page 17: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/17.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Linear Operators
Linear operators act on functions like matrices act on vectors
They are linear in that
Types of linear operators
( ) ( )( )h x L f x= o
( ) ( ) ( )L af bg a L f b L g+ = +o o o
( )( ) ( , ) ( )
( )( ) ( )
K f x k x x f x dx
fD f x xx
′ ′ ′≡
∂≡
∂
∫o
o
![Page 18: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/18.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Rendering Operators
Scattering operator
Transport operator
2
( , ) ( , ) ( , )coso o r i o i i i iH
i
L x f x L x d
S L
ω ω ω ω θ ω= →
≡
∫o
*( , ) ( ( , ), )i i o i i
o
L x L x xT L
ω ω ω= −
≡ o
![Page 19: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/19.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Solving the Rendering Equation
Rendering Equation
Solution
eL L K L= + oK S T≡ o
( ) 1eL I K L−= − o
( ) eI K L L− =o
![Page 20: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/20.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Formal Solution
Neumann series
Verify
( ) 1 21I K I K KI K
−− = = + + +−
K
( ) ( ) ( ) ( )( ) ( )
1 2
2
I K I K I K I K K
I K K K
I
−− − = − + + +
= + + − + +
=
o o KK K
![Page 21: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/21.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Successive Approximations
Successive approximations
Converged
1
2 1
1
e
e
n ne
L L
L L K L
L L K L −
=
= +
= +
oL
o
1n n n neL L L L K L−= ∴ = + o
![Page 22: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/22.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Successive Approximation
eL
e eL K L+ oeL
eK Lo eK K Lo o eK K K Lo o o
2e eL K L+L o 3
e eL K L+L o
![Page 23: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/23.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Light Path
0x
1x
2x
0 1 0 1( , ) ( , )eS x x L x x=
0 1 2 3( , , , )SL x x x x
3x
![Page 24: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/24.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Light Path
0 1 2 3 0 1 1 0 1 2 1 2 1 2 3( , , , ) ( , ) ( , ) ( , , ) ( , ) ( , , )S o r rL x x x x S x x G x x f x x x G x x f x x x=
0x
1x
2x1 2( , )G x x
0 1 2( , , )rf x x x
1 2 3( , , )rf x x x0 1( , )S x x
0 1( , )G x x
0 1 2 3( , , , )SL x x x x
![Page 25: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/25.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Light Paths
0x
1x
2x1 2( , )G x x
0 1 2( , , )rf x x x
1 2 3( , , )rf x x x0 1( , )S x x
0 1( , )G x x
2 3( , )L x x
0 1
2 3 0 1 2 3 0 1( , ) ( , , , ) ( ) ( )SA A
L x x L x x x x dA x dA x=∫∫
![Page 26: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/26.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Light Transport
Integrate over all paths of all lengths
Question:How to sample space of paths?
2 2
1
0 2 1 0 21
( , )
( , , , , ) ( ) ( )
k k
S k k k kk M M
L x x
L x x x x dA x dA x
−
∞
− − −=
=∑∫ ∫L L L
![Page 27: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/27.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Classic Ray Tracing
Forward (from eye): E S* (D|G) LFrom Heckbert
![Page 28: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/28.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
Photon Paths
From Heckbert
Caustics
Radiosity
![Page 29: The Rendering Equation](https://reader031.fdocuments.us/reader031/viewer/2022020320/56815bc7550346895dc9c030/html5/thumbnails/29.jpg)
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2007 Don Fussell
How to Solve It?
Finite element methodsClassic radiosity
Mesh surfacesPiecewise constant basis functionsSolve matrix equation
Not practical for rendering equation
Monte Carlo methodsPath tracing (distributed ray tracing)
Randomly trace ray from the eye
Bidirectional ray tracingPhoton mapping