monte carlo path tracing iii
play

Monte Carlo Path Tracing III & Operator Formulation of Light - PowerPoint PPT Presentation

Monte Carlo Path Tracing III & Operator Formulation of Light Transport CS295, Spring 2017 Shuang Zhao Computer Science Department University of California, Irvine CS295, Spring 2017 Shuang Zhao 1 Announcement PA1 will be due next


  1. Monte Carlo Path Tracing III & Operator Formulation of Light Transport CS295, Spring 2017 Shuang Zhao Computer Science Department University of California, Irvine CS295, Spring 2017 Shuang Zhao 1

  2. Announcement • PA1 will be due next Tuesday • PA2 to be released shortly after CS295, Spring 2017 Shuang Zhao 2

  3. Last Lecture • Monte Carlo Path Tracing II • BRDF sampling • Multiple importance sampling CS295, Spring 2017 Shuang Zhao 3

  4. Today’s Lecture • Monte Carlo Path Tracing III • MIS for direct illumination • Operator formulation of light transport • Ray space, throughput measure • Functions and operators • Operator formulation of the RE CS295, Spring 2017 Shuang Zhao 4

  5. Recap: Multiple Importance Sampling • To estimate • Assume there are n probability densities p 1 , p 2 , …, p n to sample x . Then, is an unbiased estimator of as long as: • for all x with • whenever CS295, Spring 2017 Shuang Zhao 5

  6. Recap: Weighting Functions • The Balance Heuristic • Then, • It holds that for any unbiased estimator (with the n densities) • In other words, as long as one provided density is “ good ”, will also be “good” CS295, Spring 2017 Shuang Zhao 6

  7. Recap: Weighting Functions • The Power Heuristic • Then, • It holds that for any unbiased estimator (with the n densities) • Sometimes works better than balance heuristic in rendering CS295, Spring 2017 Shuang Zhao 7

  8. Multiple Importance Sampling for Evaluating Direct Illumination Monte Carlo Path Tracing III CS295, Spring 2017 Shuang Zhao 8

  9. Recap: Direct Illumination CS295, Spring 2017 Shuang Zhao 9

  10. Recap: Direct Illumination • Measure: solid angle Light • Domain of integral: the unit hemisphere Ω x around the normal n x at x • Variable of integration: ω i (which determines y ) CS295, Spring 2017 Shuang Zhao 10

  11. Recap: Direct Illumination Geometric term A e • Measure: surface area Light • Domain of integral: the union A e of all light sources’ surfaces • Variable of integration: y (which determines ω i ) CS295, Spring 2017 Shuang Zhao 11

  12. Direct Illumination Estimators BRDF sampling Light sampling CS295, Spring 2017 Shuang Zhao 12

  13. MIS for Direct Illumination • In the previous slide, the two density functions p BRDF and p light have different underlying measures (i.e., solid angle vs. surface area) • To apply MIS, we need to rewrite one of the two densities so that both have the same measure • We use solid angle as the unified measure CS295, Spring 2017 Shuang Zhao 13

  14. MIS for Direct Illumination • ω i1 generated by sampling a point y on the light source and setting ω i1 = normalize( y - x ) • ω i2 generated by sampling the BRDF f r given x and ω • The key is to evaluate the four density values • Assume p light ( y ) and p BRDF ( ω ) are given • We now need rewrite p light ( ω i1 ) and p light ( ω i2 ) as densities of directions instead of surface points CS295, Spring 2017 Shuang Zhao 14

  15. Change of Measure • Observation: the ray tracing operation provides a one-to-one correspondence between all • ω i with and • with Light CS295, Spring 2017 Shuang Zhao 15

  16. Change of Measure • Observation: the ray tracing operation provides a one-to-one correspondence between all • ω i with and • with • For all such ω i and y , CS295, Spring 2017 Shuang Zhao 16

  17. Rewriting Density Functions CS295, Spring 2017 Shuang Zhao 17

  18. MIS Direct Illumination Estimator directRadianceMIS ( x , ω ): directRad = 0 [ y , p 1 ] = luminaireSample() ω i1 = normalize( y - x ) if RayTrace( x , ω i1 ) == y : p 1 *= dot( y - x , y - x ) / dot( n y , - ω i1 ) p 2 = p BRDF ( ω i1 ) directRad += emittedRadiance( y , - ω i1 ) * brdf( x , ω i1 , ω ) * dot( n x , ω i1 ) / ( p 1 + p 2 ) CS295, Spring 2017 Shuang Zhao 18

  19. MIS Direct Illumination Estimator # continue from last slide [ ω i2 , p 2 ] = brdfSample() y = RayTrace( x , ω i2 ) if y lies on a light source: p 1 = p light ( y ) * dot( y - x , y - x ) / dot( n y , - ω i2 ) directRad += emittedRadiance( y , - ω i2 ) * brdf( x , ω i2 , ω ) * dot( n x , ω i2 ) / ( p 1 + p 2 ) return directRad CS295, Spring 2017 Shuang Zhao 19

  20. Example 1 Light source BRDF (diffuse) CS295, Spring 2017 Shuang Zhao 20

  21. Example 1 Light source BRDF (shiny) CS295, Spring 2017 Shuang Zhao 21

  22. Example 2 CS295, Spring 2017 Shuang Zhao 22

  23. Operator Formulation of Light Transport CS295 Realistic Image Synthesis CS295, Spring 2017 Shuang Zhao 23

  24. Ray Space • Let be the set of surfaces in the scene, then is the ray space consisting of all light rays originating from all surface points CS295, Spring 2017 Shuang Zhao 24

  25. The Throughput Measure • Let , then the throughput measure is given by • With this measure, we can then define integrals over the ray space in the forms of CS295, Spring 2017 Shuang Zhao 25

  26. Functions on the Ray Space • Many quantities (e.g., L ) we are interested in can be interrupted as (real-valued) functions on the ray space • For any two function f and g , their inner product is defined to be CS295, Spring 2017 Shuang Zhao 26

  27. Operators • Let denote all real-valued functions on the ray space . An operator then maps a function to another function • Operators useful in our case • Local scattering operator K • Propagation operator G CS295, Spring 2017 Shuang Zhao 27

  28. Useful Operators • For any function : • The local scattering operator K : • The propagation operator G : CS295, Spring 2017 Shuang Zhao 28

  29. Operator Formulation of the RE = + CS295, Spring 2017 Shuang Zhao 29

  30. Operator Formulation of the RE (Invariant of radiance along lines) CS295, Spring 2017 Shuang Zhao 30

  31. Operator Formulation of the RE • Given the results from the previous two slides, we can rewrite the RE as • Solving the RE is effectively inverting ( I - T ) where I denotes the identity operator: CS295, Spring 2017 Shuang Zhao 31

  32. Conditions for Invertibility • When , which translates to all BRDFs conserving energy in our case, ( I - T ) is invertible and • It follows that CS295, Spring 2017 Shuang Zhao 32

  33. Next Lecture • Operator formulation of light transport II • Sensors and measurements • Adjoint operators and adjoint particle tracing CS295, Spring 2017 Shuang Zhao 33

Recommend


More recommend