Presentation is loading. Please wait.

Presentation is loading. Please wait.

Local Reflection Model Jian Huang, CS 594, Fall 2002.

Similar presentations


Presentation on theme: "Local Reflection Model Jian Huang, CS 594, Fall 2002."— Presentation transcript:

1

2 Local Reflection Model Jian Huang, CS 594, Fall 2002

3 Phong Reflection Phong specular highlight is a simplification

4 Phong Model - Limitations The Phong model is based more on common sense than physics –Perfect specular reflection only occurs on a perfect mirror surface stroke by a thin light beam It fails to handle two aspects of specular reflection that are observed in real life: –intensity varies with angle of incidence of light, increasing particularly when light nearly parallel to surface –colour of highlight DOES depend on material, and also varies with angle of incidence

5 Physically Based Specular Reflection After Phong’s work in 1975, Jim Blinn proposed physically simulated specular component In 1983, Cook and Torrance extended this model to account for the spectral composition of highlights, ie. dependencies on : Material type Angle of incidence With physically based local reflection model, can computer pre-computer BRDF

6 Modeling the Micro-geometry In reality, surfaces are not perfect mirrors A physically based approach models the surface as micro-facets Each micro-facet is a perfect reflecting surface, ie a mirror, but oriented at an angle to the average surface normal cross-section through the microfaceted surface average surface normal

7 Specular Reflection The specular reflection from this surface depends on three factors: –the number of facets oriented correctly to the viewer (remember facets are mirrors) –incident light may be shadowed, or reflected light may be masked –Fresnel’s reflectance equations predict colour change depending on angle of incidence

8 Orientation of Facets Only a certain proportion (D) of facets will in a particular direction, e.g. viewing direction H eye light

9 A Statistical Distribution Cook and Torrance give formula for D in terms of: –Gaussian distribution: D = k exp[-(  /m) 2 ]  : angle of viewer (angle between N and H) m: standard deviation of the distribution Assumptions: –Small micro-facets is still larger than the wavelength of light in size –Diameter of the light beam can intersect a large number of micro-facets to be statistically correct

10 Shadowing and Masking Light can be fully reflected Some reflected light may hit other facets Some incident light may never reach a facet Cook and Torrance give formula for G, fraction of reflected light, depending on angle of incidence and angle of view

11 Degree of Masking and Shadowing Dependent on the ratio l 1 /l 2 G = 1 - l 1 /l 2 L: light vector, V: view vector H = (L+V)/2 For masking: G m = 2(N.H)(N.V)/V.H For shadowing: G s = 2(N.H)(N.L)/V.H l2l2 l1l1

12 The Glare Term Usually, as the angle between N and V approaches 90, one sees more and more glare –You are seeing more micro-facets Need a term to account for this effect: 1/N.V

13 Recap: Snell’s Law surface reflected ray incident ray surface normal refracted ray

14 Fresnel Term In general, light is partly reflected, partly refracted Reflectance = fraction reflected reflected refracted Refractive Index:  = sin  / sin  [Note that  varies with the wavelength of light] The Fresnel term (the reflectance, F), of a perfectly smooth surface is given in terms of refractive index  of material and angle of incidence  F is wavelength dependent! N  

15 Fresnel Term Don’t know how to calculate F for arbitrary  directly, so usually started with a known or measured F 0. F is a minimum for incident light normal to the surface, ie  = 0 : F 0 = (  - 1 ) 2 / (  + 1 ) 2 So different F 0 for different materials The refractive index  of a material depends on the wavelength,, so have different F 0 for different –burnished copper has roughly: F 0,blue = 0.1, F 0,green = 0.2, F 0,red = 0.5

16 Fresnel Term As  increases from 0... F  = F 0 + ( 1 - cos  ) 5 ( 1 - F 0 ) –so, as  increases, then F  increases until F 90 = 1 (independent of  ) This means that when light is tangential to the surface: –full reflectance, independent of  –reflected colour independent of the material Thus reflectance does depend on angle of incidence Thus colour of specular reflection does depend on material and incident light angle

17 Specular Term This leads to: R s ( ) = F(  ) D G / (N.V) where: D = proportion of microfacets aligned to view G = fraction of light shadowed or masked F = Fresnel term N.V glare effect term In practice, R s is calculated for red, green, blue Note it depends on angle of incidence and angle of view

18 Cook and Torrance Reflection Model The specular term is calculated as described and combined with a uniform diffuse term: –Reflection (angle of incidence, viewing angle) = s R s + d R d (where s + d = 1) –Known as bi-directional reflectance For metals: d = 0, s = 1 For shiny plastics: d = 0.9, s = 0.1 Its BRDF does not depend on the incoming azimuth

19 Aluminium

20 Bronze

21 Chrome

22 Stainless Steel


Download ppt "Local Reflection Model Jian Huang, CS 594, Fall 2002."

Similar presentations


Ads by Google