Download presentation
Presentation is loading. Please wait.
1
Monte Carlo Path Tracing
Today Path tracing Random walks and Markov chains Eye vs. light ray tracing Bidirectional ray tracing Next Irradiance caching Photon mapping
2
Light Path Should we show the directional form of this equation?
3
Light Transport Integrate over all paths Questions
How to sample space of paths
4
Path Tracing
5
Penumbra: Trees vs. Paths
Path tracing vs. recursive ray tracing using trees Use less samples for this Superimpose paths and trees over these images 4 eye rays per pixel 16 shadow rays per eye ray 64 eye rays per pixel 1 shadow ray per eye ray
6
Path Tracing: From Camera
Step 1. Choose a camera ray r given the (x,y,u,v,t) sample weight = 1; Step 2. Find ray-surface intersection Step 3. if light return weight * Le(); else weight *= reflectance(r) Choose new ray r’ ~ BRDF pdf(r) Go to Step 2. Should illustrate this algorithm using the Cornell Box Confusion about reflectance The BRDF is not normalized to be a pdf The directional hemispherical reflectance is the correct normalization factor How to choose between Le and Lr
7
M. Fajardo Arnold Path Tracer
Return to this when discussing the adjoint formulation
8
Cornell Box: Path Tracing
Check that I am referring to these images in the correct way 10 rays per pixel 100 rays per pixel From Jensen, Realistic Image Synthesis Using Photon Maps
9
Path Tracing: Include Direct Lighting
Step 1. Choose a camera ray r given the (x,y,u,v,t) sample weight = 1; Step 2. Find ray-surface intersection Step 3. weight += Lr(light sources) Choose new ray r’ ~ BRDF pdf(r) Go to Step 2. Should illustrate this algorithm using the Cornell Box Confusion about reflectance The BRDF is not normalized to be a pdf The directional hemispherical reflectance is the correct normalization factor How to choose between Le and Lr
10
Discrete Random Walk
11
Discrete Random Process
States Creation Termination Transition Assign probabilities to each process
12
Discrete Random Process
States Creation Termination Transition Equilibrium number of particles in each state
13
Discrete Random Walk States Creation Termination
Generate random particles from sources. Undertake a discrete random walk. Count how many terminate in state i [von Neumann and Ulam; Forsythe and Leibler; 1950s] States Creation Termination Transition
14
Monte Carlo Algorithm Define a random variable on the space of paths
Probability: Estimator: Expectation:
15
Monte Carlo Algorithm Define a random variable on the space of paths
Probability: Estimator:
16
Estimator Count the number of particles terminating in state j
Do I have I,j reversed in Mi,j?
17
Equilibrium Distribution of States
Total probability of being in states P Note that this is the solution of the equation Thus, the discrete random walk is an unbiased estimate of the equilibrium number of particles in each state
18
Light Ray Tracing
19
Backward ray tracing, Arvo 1986
Examples Backward ray tracing, Arvo 1986
20
Path Tracing: From Lights
Step 1. Choose a light ray Choose a light source according to the light source power distribution function. Choose a ray from the light source radiance (area) or intensity (point) distribution function w = 1; Step 2. Trace ray to find surface intersect Step 3. Interaction
21
Path Tracing: From Lights
Step 1. Choose a light ray Step 2. Find ray-surface intersection Step 3. Interaction u = rand() if u < reflectance Choose new ray r ~ BRDF goto Step 2 else terminate on surface; deposit energy
22
Bidirectional Path Tracing
23
Bidirectional Ray Tracing
Need to make notation clear K is the number of vertices on a path K-2 is the number of bounces on the path Should probably show an example with k=4, not k=3
24
Path Pyramid From Veach and Guibas 25 samples per pixel
Combined using the power heuristic Middle image in the k=4 row Rightmost image in the bottom row 5 light-path vertices 5 steps from the floor-lamp to the table Everyone really liked this picture Understand the phenomenology behind each subimage Is there a version of this picture that contains the weights for each pixel Review multiple importance sampling: need to keep the weights and values If there are multiple samples for each pixel, Kurt suggests premultiplying by the weights and keeping a running sum of the weights. From Veach and Guibas
25
Comparison Bidirectional path tracing Path tracing
From Veach and Guibas
26
Generating All Paths
27
Adjoint Formulation
28
Symmetric Light Path All this adjoint stuff is confusing
What are the key points Can always formulate adjoint version of the problem Rendering operators are self-adjoint Solution of the adjoint equation can be used as an importance function Clear explanation with examples of why you want to reverse sources and receivers
29
Symmetric Light Path
30
Symmetric Light Path
31
Three Consequences Forward estimate equal backward estimate
- May use forward or backward ray tracing Adjoint solution - Importance sampling paths Solve for small subset of the answer
32
Example: Linear Equations
Solve a linear system Solve for a single xi? Solve the adjoint equation Source Estimator More efficient than solving for all the unknowns [von Neumann and Ulam]
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.