Part I: Basics of Computer Graphics

Slides:



Advertisements
Similar presentations
Physically Based Shading
Advertisements

1GR2-00 GR2 Advanced Computer Graphics AGR Lecture 6 Physically Based Reflection Model.
5.1 si31_2001 SI31 Advanced Computer Graphics AGR Lecture 5 A Simple Reflection Model.
SI31 Advanced Computer Graphics AGR
William A.P. Smith and Edwin R. Hancock Department of Computer Science, University of York, UK CVPR 2009 Reporter: Annie Lin.
Illumination Lighting and Shading CSE 470/598 Introduction to Computer Graphics Arizona State University Dianne Hansford.
1 Graphics CSCI 343, Fall 2013 Lecture 18 Lighting and Shading.
Local Reflection Model Jian Huang, CS 594, Fall 2002.
Virtual Realism LIGHTING AND SHADING. Lighting & Shading Approximate physical reality Ray tracing: Follow light rays through a scene Accurate, but expensive.
Foundations of Computer Graphics (Spring 2012) CS 184, Lecture 21: Radiometry Many slides courtesy Pat Hanrahan.
Physically Based Illumination Models
Advanced Computer Graphics (Spring 2013) CS 283, Lecture 8: Illumination and Reflection Many slides courtesy.
Torrance Sparrow Model of Reflectance + Oren Nayar Model of Reflectance.
1. What is Lighting? 2 Example 1. Find the cubic polynomial or that passes through the four points and satisfies 1.As a photon Metal Insulator.
Based on slides created by Edward Angel
1 Angel: Interactive Computer Graphics 5E © Addison-Wesley 2009 Shading I.
University of New Mexico
University of Texas at Austin CS395T - Advanced Image Synthesis Spring 2006 Don Fussell Previous lecture Reflectance I BRDF, BTDF, BSDF Ideal specular.
IMGD 1001: Illumination by Mark Claypool
Computer Graphics (Spring 2008) COMS 4160, Lecture 20: Illumination and Shading 2
6.1 si31_2001 SI31 Advanced Computer Graphics AGR Lecture 6 Physically Based Reflection Model.
Computer Graphics (Fall 2008) COMS 4160, Lecture 19: Illumination and Shading 2
1 CSCE 641: Computer Graphics Lighting Jinxiang Chai.
Global Illumination May 7, Global Effects translucent surface shadow multiple reflection.
7M836 Animation & Rendering
Objectives Learn to shade objects so their images appear three- dimensional Learn to shade objects so their images appear three- dimensional Introduce.
University of British Columbia CPSC 314 Computer Graphics Jan-Apr 2005 Tamara Munzner Lighting and Shading Week.
Computer Graphics (Fall 2004) COMS 4160, Lecture 16: Illumination and Shading 2 Lecture includes number of slides from.
1 Angel: Interactive Computer Graphics 4E © Addison-Wesley 2005 Shading I Ed Angel Professor of Computer Science, Electrical and Computer Engineering,
Course Website: Computer Graphics 16: Illumination.
Specular Reflections from Rough Surfaces Lecture #4 Thanks to Shree Nayar, Ravi Ramamoorthi, Pat Hanrahan.
Shading Surface can either (both) 1.Emit light. E.g. light bult 2.Reflect light. E.g. Mirror.
CS 480/680 Computer Graphics Shading I Dr. Frederick C Harris, Jr.
Illumination.
Fundamentals of Computer Graphics Part 6 Shading prof.ing.Václav Skala, CSc. University of West Bohemia Plzeň, Czech Republic ©2002 Prepared with Angel,E.:
CS 445 / 645: Introductory Computer Graphics
1 Introduction to Computer Graphics with WebGL Ed Angel Professor Emeritus of Computer Science Founding Director, Arts, Research, Technology and Science.
CS 376 Introduction to Computer Graphics 04 / 16 / 2007 Instructor: Michael Eckmann.
CSC418 Computer Graphics n Illumination n Lights n Lightinging models.
CS447/ Realistic Rendering -- Radiosity Methods-- Introduction to 2D and 3D Computer Graphics.
Advanced Illumination Models Chapter 7 of “Real-Time Rendering, 3 rd Edition”
Graphics Lecture 13: Slide 1 Interactive Computer Graphics Lecture 13: Radiosity - Principles.
Diffuse Reflections from Rough Surfaces Lecture #5
Computer Graphics: Programming, Problem Solving, and Visual Communication Steve Cunningham California State University Stanislaus and Grinnell College.
Reflection models Digital Image Synthesis Yung-Yu Chuang 11/01/2005 with slides by Pat Hanrahan and Matt Pharr.
1 Introduction to Computer Graphics with WebGL Ed Angel Professor Emeritus of Computer Science Founding Director, Arts, Research, Technology and Science.
Global Illumination: Radiosity, Photon Mapping & Path Tracing Rama Hoetzlein, 2009 Lecture Notes Cornell University.
Photo-realistic Rendering and Global Illumination in Computer Graphics Spring 2012 Material Representation K. H. Ko School of Mechatronics Gwangju Institute.
CSCE 641 Computer Graphics: Reflection Models Jinxiang Chai.
Computer Graphics (Spring 2003) COMS 4160, Lecture 18: Shading 2 Ravi Ramamoorthi Guest Lecturer: Aner Benartzi.
02/2/05© 2005 University of Wisconsin Last Time Reflectance part 1 –Radiometry –Lambertian –Specular.
1 CSCE 441: Computer Graphics Lighting Jinxiang Chai.
Local Reflection Models
OpenGL Shading. 2 Objectives Learn to shade objects so their images appear three-dimensional Introduce the types of light-material interactions Build.
1 CSCE 441: Computer Graphics Lighting Jinxiang Chai.
David Luebke3/16/2016 CS 551 / 645: Introductory Computer Graphics David Luebke
Physically-based Illumination Models (2) CPSC 591/691.
CS552: Computer Graphics Lecture 33: Illumination and Shading.
Computer Graphics Lecture 30 Mathematics of Lighting and Shading - IV Taqdees A. Siddiqi
1 CSCE 441: Computer Graphics Lighting Jinxiang Chai.
Light. Intensity calculation = wavelength I( ) = wavelength intensity of light reaching eye I( ) = I diff ( ) + I spec ( ) + I refl ( ) + I trans ( )
Reflection Models (1) Physically-Based Illumination Models (2)
Reflectance Models CS 319 Advanced Topics in Computer Graphics John C. Hart.
Computer Graphics: Illumination
7. Illumination Phong Illumination Diffuse, Specular and Ambient
Advanced Computer Graphics
Previous lecture Reflectance I BRDF, BTDF, BSDF Ideal specular model
CSE 470 Introduction to Computer Graphics Arizona State University
CS5500 Computer Graphics May 29, 2006
CS 480/680 Computer Graphics Shading.
Presentation transcript:

Part I: Basics of Computer Graphics Chapter 5 Representing Light and Isotropic Reflection Models 6-1

How do we represent light? RGB? No! Light spectrum: Therefore shading calculation should be performed on the light spectrum. How? Taking samples on the spectrum. [Hall89] proposed to take 9 samples on the curves. Calculate shading for each sampled wavelength, e.g. invoke Phong reflection model “9” times. 5-2

How do we represent light? Is the surface reflectivity also wavelength dependent? YES! But “How can we display the final light spectrum on the RGB monitor?” Different spectrums may produce same response in our eyes. Hence no need to reproduce the exact light spectrum. But reproduce another spectrum that gives us the “same” perceptual color. 5-3

Color Matching Experiment Three types of color receptors (cones) on our retina: responsible for short, middle and long wavelengths A matching experiment of Sensations, not matching of spectral curve. A statistical, psychological experiment. May vary for different individual. 5-4

Color Matching Experiment 3 lights are chosen X: 445nm Y: 535nm Z: 630nm Not necessary equal to RGB on your monitor e.g. wavelength 570nm has the same response as 0 X + 0.7 Y + 1.0 Z 5-5

From Light Spectrum to RGB An ideal sampling approach: Take 9 samples on the spectral curve. Invokes reflection models (say Phong model) 9 times. Convert the light spectrum to XYZ From XYZ to RGB: spectral curve of RGB primitives can also be expressed as, R = a X + b Y + c Z G = d X + e Y + f Z B = g X + h Y + i Z In other words, 5-6

From Light Spectrum to RGB Practically, most graphics systems don’t care. They only sample at 3 wavelength R G B. Obviously, it is not accurate or correct. Two monitors may not display the same image equally. Reference [Hall89] Roy Hall, Illumination and Color in Computer Generated Imagery, Springer-Verlag 1989. 5-7

Phong Reflection Model Notation: Many variations, the following is a common model: reflected = ambient + diffuse + specular Ambient Models the contribution of the surrounding environment except the light sources. It is assumed constant. Obviously wrong! Phong model is a local illumination model. Global illumination models (ray-tracing, radiosity) solve this more accurately. 6-2

Phong Reflection Model Diffuse Models multiple scattering within rough surface Viewpoint independent Depends on cos q, since the surface element is not maximally illuminated if the light source is not from the top. cos q projects the surface elements along the L direction. 6-3

6-4

Phong Reflection Model Specular Model the glossy appearance of shiny object. Viewpoint dependent Efficient modification: N.H replaces R.V Diffuse + Specular 6-5

6-6

6-7

Torrance-Sparrow Model Comparing Phong model with real surface. Phong real surface Flaw 1: height of the specular bump varies with the direction of light source. Flaw 2: direction of peak specular reflection is not exactly along the mirror reflection direction. Off-specular reflection phenomenon Both flaws related to the specular reflection. 6-8

Torrance-Sparrow Model In 1967, Torrance and Sparrow [Torrance67] proposed a reflection model based on microfacet approach. It accounts for the off-specular phenomenon. Blinn [Blinn77] proposed a reflection model for computer graphics based on Torrance-Sparrow model. Modifications are done for the specular term. D, Distribution function of the directions of microfacets on the rough surface. G, Geometry attenuation factor due to self-shadowing or masking F, Fresnel reflection (physical law). 6-9

Ni a Distribution Function Models the surface roughness using a statistical function Several functions have been proposed Guassian distribution (normal distribution) a is the angle from the average normal N to the facet normal Ni m controls the bell shape (standard derivation) of the Guassian function Beckmann model m is the RMS (root mean square) slope of microfacets, actually a parameter to control the shape of the bump a Ni 6-10

Distribution Function Most models use Guassian distribution as a component. Easy to handle. May derive close-form solution Frequently found in natural phenomenon (A claim). Replace the cos function in Phong Model by this factor 6-11

Case a Case b Case c Geometry Attenuation Accounts for self-shadowing or masking Explains off-specular reflection phenomenon Case a Case b Case c 6-12

each facet comprises one side of a symmetric V-groove cavity Geometry Attenuation To calculate geometry attenuation factor G,we assume each facet comprises one side of a symmetric V-groove cavity longitudinal axis of the cavity is parallel to the plane of the mean surface upper edges of V-grooves are all in the same plane the grooves do not have a preferred orientation, i.e., they are in all directions along the surface But, the assumptions are not realistic. However, it does explain the off-specular reflection. For cases b and c, the attenuation equals to the factor (reuse m) 6-13

Geometry Attenuation Case c: L & V interchange 6-14

Fresnel Reflection The fraction of light incident on a facet which is actually reflected (as opposed to being absorbed). qi is angle of incidence sin qt = sin qi / n where is refraction index It can be rewritten as where When qi =p/2, no absorption, all reflected. qi =0, max absorption. 6-15

References [Blinn77] James F. Blinn, “Models of Light Reflection For Computer Synthesized Pictures”, SIGGRAPH Proceedings’ 77, p192-198, 1977. [Cook81] Robert Cook and Kenneth Torrance, “A Reflectance Model for Computer Graphics”, SIGGRAPH Proceedings’81, p307-316, 1981. [Phong75] Bui-Tuong Phong, “Illumination for Computer Generated Images”, Communcation of ACM, vol. 18, no. 6, p311-317, 1975. [Torrance67] Kenneth Torrance and Ephraim Sparrow, “Theory for Off-Specular Reflection from Roughened Surface”, Journal of Optical Society of America, vol. 57, no. 9, 1967. 6-16