Last Time Reflectance part 1 Radiometry Lambertian Specular
Last Time • Reflectance part 1 – Radiometry – Lambertian – Specular 02/2/05 © 2005 University of Wisconsin
Today • Microfacet models – Diffuse • Oren-Nayar – Specular • Torrance-Sparrow – Blinn – Ashikhmin-Shirley – Ward – Schlick • Lafortune’s model • Glossy over Diffuse 02/2/05 © 2005 University of Wisconsin
Microfacet Models (PBR 9. 4) • Model fine detail as set of polygonal facets – Metals – Minerals – Things that solidified in crystal form, or were broken/cut by fracture/scraping • Aim to capture the macroscopic effects of the many microscopic facets 02/2/05 © 2005 University of Wisconsin
Describing Microfacet Materials • Surface normal distribution – How the surface normals of the facets are distributed about the macroscopic normal • Facet BRDF – Are the facets diffuse or specular? 02/2/05 © 2005 University of Wisconsin
Microscopic Effects • • Masking – viewer can’t see a microfacet Shadowing – light can’t see a microfacet Interreflection – light off one facet hits another Aim is to capture these effects as efficiently as possible 02/2/05 © 2005 University of Wisconsin
Oren-Nayar (PBR 9. 4. 1) • • Model facet distribution as Gaussian with s. d. (in radians) Facet BRDF is Lambertian Resulting model has no closed form solution, but a good approximation Sample using cosine-weighted sampling in hemisphere 02/2/05 © 2005 University of Wisconsin
Oren-Nayar Effects Lambertian 02/2/05 Oren-Nayar © 2005 University of Wisconsin
Torrance-Sparrow (PBR Sect 9. 4. 2) • Specular BRDF for facets • Arbitrary (in theory) distribution of facet normals • Additional term for masking and shadowing i n h Half vector – facet orientation to get specular transfer o 02/2/05 © 2005 University of Wisconsin
Torrance-Sparrow BRDF • D( h) is the microfacet orientation distribution evaluated for the half angle – Changing this changes the surface appearance – but this equation doesn’t depend on the choice • Fr( o) is the Fresnel reflection coefficient 02/2/05 © 2005 University of Wisconsin
Geometry Term • Masking: • Shadowing: • Together: 02/2/05 © 2005 University of Wisconsin
Blinn’s Microfacet Distribution • Parameter e controls “roughness” 02/2/05 © 2005 University of Wisconsin
Sampling Blinn’s Microfacet (PBR 15. 5. 1) • Sampling from a Microfacet BRDF tries to account for all the terms: G, D, F, cos • But D provides most variation, so sample according to D • The sampled direction is completely determined by halfway vector, h, so sample that – Then construct reflection ray based upon it • So how do we sample such a direction … 02/2/05 © 2005 University of Wisconsin
More Blinn Sampling • Need to sample spherical coords: , • Book has details, and probably an error on page 684 • Complication: We need to return the probability of choosing i, but we have the probability of choosing h – Simple conversion term • We need to construct the reflection direction about an arbitrary vector … 02/2/05 © 2005 University of Wisconsin
Arbitrary Reflection • Coordinate system is not nicely aligned, so use construction 02/2/05 © 2005 University of Wisconsin
Anisotropic Microfacet Distribution • Parameters for x and y direction roughness, where x and y are the local BRDF coordinate system on the surface – Gives the reference frame for 02/2/05 © 2005 University of Wisconsin
Sampling Anisotropic Microfacet • Sampling is discussed in PBR Sect 15. 5. 2 – similar to Blinn but with different distribution, and probably not quite right – Note that there are 4 symmetric quadrants in the tangent plane – Sample in a single quadrant, then map to one of 4 quadrants – Take care to maintain stratification 0 1 1 st 02/2/05 2 nd 3 rd © 2005 University of Wisconsin 4 th
Ward’s Isotropic Model • “the simplest empirical formula that will do the job” • Leaves out the geometry and Fresnel terms – Makes integration and sampling easier • 3 terms, plus some angular values: – d is the diffuse reflectance – s is the specular reflectance – is the standard deviation of the micro-surface slope 02/2/05 © 2005 University of Wisconsin
Ward’s Anisotropic Model • For surfaces with oriented grooves • 2 terms for anisotropy: – x is the standard deviation of the surface slope in the x direction – y is the standard deviation of the surface slope in the y direction 02/2/05 © 2005 University of Wisconsin
Sampling Ward’s Model • Take 1 and 2 and transform to get h and h: • Only samples one quadrant, use same trick as before to get all quadrants • Not sure about correct normalization constant for solid angle measure 02/2/05 © 2005 University of Wisconsin
Schlick’s Model (Schlick 94) • Empirical model well suited to sampling • Two parameters: – , a roughness factor (0 = Specular, 1 = Lambertian) – , an anisotropy term, (0 perfectly anisotropic, 1 = isotropic) 02/2/05 © 2005 University of Wisconsin
Schlick’s Model • Facet Distribution: • Geometry Terms: 02/2/05 © 2005 University of Wisconsin
Putting it Together • Term to account for inter-reflection • Not a Torrance-Sparrow model • As before, sample a half vector: – Only samples in 1 quadrant • Use trick from before – Normalization not given 02/2/05 © 2005 University of Wisconsin
More to it than that • Both Ward and Schlick’s original papers define complete reflectance, including diffuse and pure specular components • PBR calls these materials, because they are simply linear sums of individual components • Schlick’s paper also includes a way to decide how to combine the diffuse, specular and glossy terms based on the roughness • Both Ward and Schlick discuss sampling from the complete distribution 02/2/05 © 2005 University of Wisconsin
Phong Revisited • The Phong Specularity model can be revised to make it physically viable – energy conserving and reciprocal • In canonical BRDF coordinate system (z axis is normal) 02/2/05 © 2005 University of Wisconsin
Oriented Phong • Define an orientation vector – the direction in which the Phong reflection is strongest • For standard Phong, o=(-1, 1) • To get “off specular” reflection, change o – Can get retro-reflection, more reflection at grazing, etc. 02/2/05 © 2005 University of Wisconsin
Lafortune’s Model (PBR 9. 5) • A diffuse component plus a sum of Phong lobes • Allow all parameters to vary with wavelength • Lots of parameters, 12 for each lobe, so suited for fitting to data – It’s reasonably easy to fit – Parameters for many surfaces are available 02/2/05 © 2005 University of Wisconsin
Lafortune’s Clay 02/2/05 © 2005 University of Wisconsin
Sampling From Lafortune • First choose a lobe (or diffuse) – Could be proportional to lobe’s contribution to outgoing direction – But that might be expensive • Then sample a direction according to that lobe’s distribution – Just like sampling from Blinn’s microfacet distribution, but sampling the direction directly 02/2/05 © 2005 University of Wisconsin
Two-Layer Models (PBR 9. 6 and 15. 5. 3)) • Captures the effects of a thin glossy layer over a diffuse substrate – Common in practice – polished painted surfaces, polished wood, … • Glossy dominates at grazing angles, diffuse dominates at near-normal angles – Don’t need to trace rays through specular surface to hit diffuse 02/2/05 © 2005 University of Wisconsin
Fresnel Blend Model 02/2/05 © 2005 University of Wisconsin
Next Time • Some specialized reflectance models • Light sources • Then we can start making pictures 02/2/05 © 2005 University of Wisconsin
- Slides: 31