![Page 1: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/1.jpg)
Time-Dependent Photon Mapping
Mike Cammarano
Henrik Wann Jensen
EGWR ‘02
![Page 2: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/2.jpg)
Standard Photon Map
Two-pass algorithm:
1. Photon trace
2. Rendering
![Page 3: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/3.jpg)
First Pass - Photon Trace
For 100 photons emitted from 100W source, each photon initially carries 1W.
Propagate this radiant flux through scene using MC methods.
![Page 4: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/4.jpg)
Estimating incident flux
• At any patch of surface, we can estimate the incident flux:
Just average the contributions of all the photons that hit the patch.
![Page 5: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/5.jpg)
A Photon
• For each surface interaction, we store:
struct photon {
float x,y,z; // position
char power[4]; // power (RGBE)
char phi, theta; // incident direction
short flag;
}
![Page 6: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/6.jpg)
Photon Storage
Store this information about surface
interactions in photon map (kd-tree)
Photon storage is decoupled from geometry
![Page 7: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/7.jpg)
Second Pass - Rendering
• Estimate flux incident at a surface point based on nearby photons.
![Page 8: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/8.jpg)
Radiance Estimate
Expand ball until it contains some reasonable number of photons.
Use intersection with plane to estimate area of surface patch.
![Page 9: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/9.jpg)
Radiance Estimate
![Page 10: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/10.jpg)
What About Motion?
![Page 11: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/11.jpg)
One Approach
• Render lots of intermediate frames independent of one another.
![Page 12: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/12.jpg)
Average Intermediate Frames
![Page 13: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/13.jpg)
Expensive
• Only some areas need to be densely sampled in time.
• Need MANY intermediate frames to get smooth results.
![Page 14: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/14.jpg)
Adaptive Sampling
• Want to sample densely in time only for the pixels that need it.
• Easy with ray tracing. Can trace each ray for a different time in the interval. [Cook84]
![Page 15: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/15.jpg)
Photon Map
• We can’t rebuild the photon map for every eye-ray with a different time!
• We would like to do DRT with photons, too.
• Given rays sampling various times and photons representing lighting at various times, how do we match them up?
![Page 16: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/16.jpg)
Photons distributed in time
t=0.0 t=0.5 t=1.0
![Page 17: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/17.jpg)
Energy
Radiant Flux Radiant Energy
![Page 18: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/18.jpg)
Time-Dep. Radiance Estimate
![Page 19: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/19.jpg)
Static surface, no occlusion
![Page 20: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/20.jpg)
Photons in time
• Want average radiance ( ∫ … dt )
![Page 21: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/21.jpg)
Time distribution
![Page 22: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/22.jpg)
Average over time
![Page 23: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/23.jpg)
Case 1
For stationary surfaces with unobstructed visibility through the entire view interval, we can ignore time distribution of photons.
![Page 24: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/24.jpg)
Plane Moving Down
t=0.0
t=0.5
t=1.0
![Page 25: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/25.jpg)
Photon Visualization
t=0.0
t=0.5
t=1.0
![Page 26: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/26.jpg)
A Trickier Case
t=0.0
t=0.5
t=1.0
Average of independent frames Distributed photon times
![Page 27: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/27.jpg)
Examples
![Page 28: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/28.jpg)
Problem
• A given patch of surface is only visible through a particular pixel for a small portion of the total time interval.
• It’s brightness during that visible interval should depend only on the photons reaching it during that narrow window of time – not the “average” over all times.
![Page 29: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/29.jpg)
Distribution in Time
Uncounted!
![Page 30: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/30.jpg)
Narrow Window in Time
• Integrate over small visible interval.
![Page 31: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/31.jpg)
Comparison
![Page 32: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/32.jpg)
Performance
• Path tracing 9+ hrs
• Average of independent frames 47 sec
• TDPM 43 sec
• Our worst case: we get essentially no benefit from adaptive sampling – doesn’t cost much to oversample blue background.
• Try it in front of ~107 polygon forest …
![Page 33: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/33.jpg)
Summary of Method
IF ray-path from eye is unaffected by motion:Can integrate over entire time interval – Δt = 1.(Use all the spatially nearby photons in the estimate)
ELSEIntegrate over shorter visible interval.Can use several criteria for choosing Δt adaptively:
1. Δt < user-specified MaxΔt
2. Δt chosen to use only k-nearest-photons-in-time
3. Δt < time spanned by the photons
![Page 34: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/34.jpg)
Truck Scene
![Page 35: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/35.jpg)
Effect
![Page 36: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/36.jpg)
Comparison
Average of 9 frames - 316 seconds
![Page 37: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/37.jpg)
Comparison
Our method – 72 seconds
![Page 38: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/38.jpg)
Comparison
Ignoring case for eye-paths with movement
![Page 39: Time-Dependent Photon Mapping Mike Cammarano Henrik Wann Jensen EGWR ‘02](https://reader035.vdocuments.us/reader035/viewer/2022062421/56649d615503460f94a4288e/html5/thumbnails/39.jpg)
Conclusion
• Can incorporate correct global illumination via photon mapping in a ray-tracer that adaptively samples in time.
• Computing photon map with time-dependence requires little or no added cost beyond photon mapping for the corresponding still scene.
• Better performance than alternative methods for animated global illumination.