to do
play

To Do Computer Graphics (Fall 2004) Submit HW 3, do well Start - PDF document

To Do Computer Graphics (Fall 2004) Submit HW 3, do well Start early on HW 4 COMS 4160, Lecture 16: Illumination and Shading 2 http://www.cs.columbia.edu/~cs4160 Lecture includes number of slides from other sources: Hence different


  1. To Do Computer Graphics (Fall 2004) • Submit HW 3, do well • Start early on HW 4 COMS 4160, Lecture 16: Illumination and Shading 2 http://www.cs.columbia.edu/~cs4160 Lecture includes number of slides from other sources: Hence different color scheme to be compatible with these other sources Outline Motivation • Preliminaries • Lots of ad-hoc tricks for shading • Basic diffuse and Phong shading – Kind of looks right, but? • Gouraud, Phong interpolation, smooth shading • Study this more formally • Formal reflection equation • Physics of light transport • Texture mapping (next week) – Will lead to formal reflection equation • Global illumination (next unit) • One of the more technical/theoretical lectures See handout (chapter 2 of Cohen and Wallace) – But important to solidify theoretical framework Building up the BRDF • Bi-Directional Reflectance Distribution Function [Nicodemus 77] • Function based on incident, view direction • Relates incoming light energy to outgoing light energy • We have already seen special cases: Lambertian, Phong • In this lecture, we study all this abstractly

  2. Radiometry • Physical measurement of electromagnetic energy • We consider light field – Radiance, Irradiance – Reflection functions: Bi-Directional Reflectance Distribution Function or BRDF – Reflection Equation – Simple BRDF models Radiance • Power per unit projected area perpendicular to the ray per unit solid angle in the direction of the ray • Symbol: L(x, ω ) (W/m 2 sr) • Flux given by d Φ = L(x, ω ) cos θ d ω dA Radiance properties • Radiance is constant as it propagates along ray – Derived from conservation of flux – Fundamental in Light Transport. Φ = ω = ω = Φ d L d dA L d dA d 1 1 1 2 2 2 1 2 ω = ω = d dA r 2 d dA r 2 1 2 2 1 dA dA ω = = ω d dA 1 2 d dA 1 1 2 2 r 2 ∴ = L L 1 2

  3. Radiance properties • Sensor response proportional to surface radiance (constant of proportionality is throughput) – Far away surface: See more, but subtends smaller angle – Wall is equally bright across range of viewing distances Consequences – Radiance associated with rays in a ray tracer – All other radiometric quantities derived from radiance Irradiance, Radiosity • Irradiance E is the radiant power per unit area • Integrate incoming radiance over hemisphere – Projected solid angle (cos θ d ω ) – Uniform illumination: Irradiance = π [CW 24,25] – Units: W/m 2 • Radiosity – Power per unit area leaving surface (like irradiance) BRDF • Reflected Radiance proportional to Irradiance • Constant proportionality: BRDF [CW pp 28,29] – Ratio of outgoing light (radiance) to incoming light (irradiance) – Bidirectional Reflection Distribution Function – (4 Vars) units 1/sr ω L ( ) r r ω ω = f ( , ) i r ω θ ω L ( )cos d i i i i ω = ω ω ω θ ω L ( ) L ( ) ( f , )cos d r r i i i r i i

  4. Isotropic vs Anisotropic • Isotropic: Most materials (you can rotate about normal without changing reflections) • Anisotropic: brushed metal etc. preferred tangential direction Anisotropic Isotropic Reflection Equation Radiometry • Physical measurement of electromagnetic energy • We consider light field ω ω i – Radiance, Irradiance r – Reflection functions: Bi - D irectional Reflectance Distribution Function or BRDF ω = ω ω ω ω L ( ) L ( ) ( f , )( i n ) – Reflection Equation r r i i i r i – Simple BRDF models Reflected Radiance Incident BRDF Cosine of radiance (from Incident angle (Output Image) light source) Reflection Equation Reflection Equation ω ω d ω ω ω i i r r i Sum over all light sources = ∫ Replace sum with integral = ∑ ω ω ω ω ω ω ω ω ω ω ω L ( ) L ( ) ( f , )( i n ) L ( ) L ( ) ( f , )( i n d ) r r i i i r i r r i i i r i i i Ω Incident BRDF Cosine of Incident BRDF Cosine of Reflected Radiance Reflected Radiance (Output Image) radiance (from Incident angle (Output Image) radiance (from Incident angle light source) light source)

  5. Radiometry Brdf Viewer plots • Physical measurement of electromagnetic energy • We consider light field – Radiance, Irradiance Diffuse Torrance-Sparrow – Reflection functions: Bi - D irectional Anisotropic Reflectance Distribution Function or BRDF – Reflection Equation – Simple BRDF models bv written by Szymon Rusinkiewicz

  6. Analytical BRDF: TS example Torrance-Sparrow • Assume the surface is made up grooves at the • One famous analytically derived BRDF is microscopic level. the Torrance-Sparrow model. • T-S is used to model specular surface, like the Phong model. • Assume the faces of these grooves (called – more accurate than Phong microfacets) are perfect reflectors. – has more parameters that can be set to match • Take into account 3 phenomena different materials – derived based on assumptions of underlying geometry. (instead of ‘because it works well’) Shadowing Masking Interreflection Torrance-Sparrow Result Other BRDF models Geometric Attenuation: Fresnel term: reduces the output based on the allows for wavelength amount of shadowing or masking dependency • Empirical: Measure and build a 4D table that occurs. • Anisotropic models for hair, brushed steel Distribution: θ ω ω θ F ( ) ( G , ) D ( ) distribution function i i r h = • Cartoon shaders, funky BRDFs f determines what θ θ 4cos( )cos( ) percentage of i r • Capturing spatial variation microfacets are How much of the oriented to reflect in macroscopic surface • Very active area of research How much of the the viewer direction. is visible to the light macroscopic source surface is visible to the viewer Complex Lighting Environment Maps • Instead of determining the lighting direction by knowing what lights exist, determine what • So far we’ve looked at simple, discrete light exists by knowing the lighting direction. light sources. • Real environments contribute many colors of light from many directions. • The complex lighting of a scene can be captured in an Environment map. – Just paint the environment on a sphere. Blinn and Newell 1976, Miller and Hoffman, 1984 Later, Greene 86, Cabral et al. 87

  7. Conclusion • All this (OpenGL, physically based) are local illumination and shading models • Good lighting, BRDFs produce convincing results – Matrix movies, modern realistic computer graphics • Do not consider global effects like shadows, interreflections (from one surface on another) – Subject of next unit (global illumination)

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend