CS552: Computer Graphics Lecture 33: Illumination and Shading.

Slides:



Advertisements
Similar presentations
The Radiance Equation.
Advertisements

GR2 Advanced Computer Graphics AGR
SI31 Advanced Computer Graphics AGR
13.1 si31_2001 SI31 Advanced Computer Graphics AGR Lecture 13 An Introduction to Ray Tracing.
Computer Vision Radiometry. Bahadir K. Gunturk2 Radiometry Radiometry is the part of image formation concerned with the relation among the amounts of.
1 Graphics CSCI 343, Fall 2013 Lecture 18 Lighting and Shading.
CAP 4703 Computer Graphic Methods Prof. Roy Levow Chapter 6.
Computer graphics & visualization Global Illumination Effects.
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.
Radiometry. Outline What is Radiometry? Quantities Radiant energy, flux density Irradiance, Radiance Spherical coordinates, foreshortening Modeling surface.
Physically Based Illumination Models
Illumination Models Radiosity Chapter 14 Section 14.7 Some of the material in these slides may have been adapted from University of Virginia, MIT, Colby.
Photo-realistic Rendering and Global Illumination in Computer Graphics Spring 2012 Material Representation K. H. Ko School of Mechatronics Gwangju Institute.
Graphics Graphics Korea University cgvr.korea.ac.kr Illumination Model 고려대학교 컴퓨터 그래픽스 연구실.
Advanced Computer Graphics (Spring 2013) CS 283, Lecture 8: Illumination and Reflection Many slides courtesy.
Ray Tracing & Radiosity Dr. Amy H. Zhang. Outline  Ray tracing  Radiosity.
1 Computer Graphics By : Mohammed abu Lamdy ITGD3107 University of Palestine Supervision: Assistant Professor Dr. Sana’a Wafa Al-Sayegh.
Light Issues in Computer Graphics Presented by Saleema Amershi.
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.
IMGD 1001: Illumination by Mark Claypool
Advanced Computer Graphics (Fall 2010) CS 283, Lecture 10: Global Illumination Ravi Ramamoorthi Some images courtesy.
Computer Graphics (Fall 2008) COMS 4160, Lecture 19: Illumination and Shading 2
Introduction to Computer Vision CS / ECE 181B Tues, May 18, 2004 Ack: Matthew Turk (slides)
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.
CSCE 641 Computer Graphics: Radiosity Jinxiang Chai.
CSCE 441 Computer Graphics: Radiosity Jinxiang Chai.
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.
CS 480/680 Computer Graphics Shading I Dr. Frederick C Harris, Jr.
CSC418 Computer Graphics n Raytracing n Shadows n Global Illumination.
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.
MIT EECS 6.837, Durand and Cutler Local Illumination.
-Global Illumination Techniques
CS 376 Introduction to Computer Graphics 04 / 16 / 2007 Instructor: Michael Eckmann.
CSC418 Computer Graphics n Illumination n Lights n Lightinging models.
David Luebke 1 10/26/2015 Lighting CS 445/645 Introduction to Computer Graphics David Luebke, Spring 2003.
University of Texas at Austin CS 378 – Game Technology Don Fussell CS 378: Computer Game Technology Basic Rendering Pipeline and Shading Spring 2012.
Announcements Office hours today 2:30-3:30 Graded midterms will be returned at the end of the class.
04/30/02(c) 2002 University of Wisconsin Last Time Subdivision techniques for modeling We are now all done with modeling, the standard hardware pipeline.
Illumination and Shading
1 Introduction to Computer Graphics with WebGL Ed Angel Professor Emeritus of Computer Science Founding Director, Arts, Research, Technology and Science.
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.
In the name of God Computer Graphics. Last Time Some techniques for modeling Today Global illumination and raytracing.
Cornell CS465 Spring 2004 Lecture 4© 2004 Steve Marschner 1 Shading CS 465 Lecture 4.
Illumination and Shading Prof. Lizhuang Ma Shanghai Jiao Tong University.
Illumination 2013, Fall. Ray Casting Image RayCast(Camera camera, Scene scene, int width, int height) { Image image = new Image(width, height); for (int.
1 CSCE 441: Computer Graphics Lighting Jinxiang Chai.
CS 445 / 645 Introduction to Computer Graphics Lecture 16 Lighting Lighting.
Distributed Ray Tracing. Can you get this with ray tracing?
Distributed Ray Tracing. Can you get this with ray tracing?
1 CSCE 441: Computer Graphics Lighting Jinxiang Chai.
Computer Graphics Ken-Yi Lee National Taiwan University (the slides are adapted from Bing-Yi Chen and Yung-Yu Chuang)
Computer Graphics: Illumination
Illumination and Shading Prof. Lizhuang Ma Shanghai Jiao Tong University.
7. Illumination Phong Illumination Diffuse, Specular and Ambient
Illumination 2016, Fall.
Shading Revisited Some applications are intended to produce pictures that look photorealistic, or close to it The image should look like a photograph A.
Illumination and Shading
GR2 Advanced Computer Graphics AGR
Illumination Model 고려대학교 컴퓨터 그래픽스 연구실.
Illumination Model 고려대학교 컴퓨터 그래픽스 연구실.
CS 480/680 Computer Graphics Shading.
Presentation transcript:

CS552: Computer Graphics Lecture 33: Illumination and Shading

Recap Solid Modeling o Represent the solid object in a 3D space o B-Reps o Subdividing algorithms

Objective After completing this lecture, students will be able to o Explain the importance of VSDs o Solve the problem of backface culling

Surface Rendering Method Realistic displays of a scene are obtained by o Generating perspective projections of objects and o Applying natural lighting effects to the visible surfaces An illumination model is used to calculate the color of an illuminated position on the surface of an object. A surface-rendering method uses the color calculations from an illumination model to determine the pixel colors for all projected positions in a scene.

Global Illumination Direct illumination + Indirect illumination = Total illumination

Diffuse Inter-reflection Total illumination (normal image)

Diffuse Inter-reflection Direct illumination

Diffuse Interreflection Indirect illumination (diffuse interreflection)

Human face Total illumination (normal image)

Human face Direct illumination

Human face Indirect illumination

Illumination How do We Compute Radiance for a Sample Ray? o Must derive computer models for...  Emission at light sources  Scattering at surfaces  Reception at the camera WireframeWithout Illumination Direct Illumination

Overview Direct Illumination o Emission at light sources o Scattering at surfaces Global Illumination o Shadows o Refractions o Inter-object reflections Direct Illumination

Overview Direct Illumination o Emission at light sources o Scattering at surfaces Global Illumination o Shadows o Refractions o Inter-object reflections Direct Illumination

Modeling Light Source I L (x,y,z,  ) o Describes the intensity of energy, o Leaving a light source o Arriving at location(x,y,z) o From direction (  ) o With wavelength

Empirical Model Ideally Measure Irradiant Energy for “All” Situations o Too much storage o Difficult in practice

Light Source Model Simple Mathematical Models: o Point light o Directional light o Spot light

Point Light Source Models Omni-Directional Point Source (E.g., Bulb) o Intensity (I 0 ) o Position (px, py, pz) o Factors (k c, k l, k q ) for attenuation with distance (d)

Directional Light Source Models Point Light Source at Infinity (E.g., Sun) o Intensity (I 0 ) o Direction (dx,dy,dz) No attenuation with distance

Spot Light Source Models Point Light Source with Direction o Intensity (I 0 ), o Position (px, py, pz) o Direction (dx, dy, dz) o Attenuation

Directional Light Sources

Angular Intensity Attenuation Attenuate the light intensity o Angularly about the source o Radially out from the point-source position.

Overview Direct Illumination o Emission at light sources o Scattering at surfaces Global Illumination o Shadows o Refractions o Inter-object reflections Direct Illumination

Modeling Surface Reflection R s ( ,  ) o Describes the amount of incident energy o Arriving from direction (  ) o Leaving in direction ( ,  ) o With wavelength

Empirical Model Ideally Measure Radiant Energy for “All” Combinations of Incident Angles o Too much storage o Difficult in practice

Reflectance Model Simple Analytic Model: o Diffuse reflection + o Specular reflection + o Emission + o “Ambient” Based on model proposed by Phong Based on model proposed by Phong

Reflectance Model Simple Analytic Model: o Diffuse reflection + o Specular reflection + o Emission + o “Ambient” Based on model proposed by Phong Based on model proposed by Phong

Diffuse Reflection Assume Surface Reflects Equally in All Directions o Examples: chalk, clay

Diffuse Reflection How Much Light is Reflected? o Depends on angle of incident light o dL  dA  cos 

Diffuse Reflection Lambertian Model o Cosine law (dot product)

Reflectance Model Simple Analytic Model: o Diffuse reflection + o Specular reflection + o Emission + o “Ambient” Based on model proposed by Phong Based on model proposed by Phong

Specular Reflection Reflection is Strongest Near Mirror Angle o Examples: mirrors, metals

Specular Reflection How Much Light is Seen? o Depends on angle of incident light and angle to viewer

Specular Reflection Phong Model o {cos(  )} n

Reflectance Model Simple Analytic Model: o Diffuse reflection + o Specular reflection + o Emission + o “Ambient” Based on model proposed by Phong Based on model proposed by Phong

Emission Represents Light Emitting Directly From Polygon Emission ≠ 0

Reflectance Model Simple Analytic Model: o Diffuse reflection + o Specular reflection + o Emission + o “Ambient” Based on model proposed by Phong Based on model proposed by Phong

Ambient Term Represents Reflection of All Indirect Illumination

Reflectance Model Simple Analytic Model: o Diffuse reflection + o Specular reflection + o Emission + o “Ambient”

Reflectance Model Simple Analytic Model: o Diffuse reflection + o Specular reflection + o Emission + o “Ambient”

Reflectance Model Sum Diffuse, Specular, Emission, and Ambient

Surface Illumination Calculation Single Light Source:

Surface Illumination Calculation Multiple Light Sources:

Overview Direct Illumination o Emission at light sources o Scattering at surfaces Global Illumination o Shadows o Refractions o Inter-object reflections Global Illumination

Shadows Shadow Terms Tell Which Light Sources are Blocked o Cast ray towards each light source L i o S i = 0 if ray is blocked, S i = 1 otherwise Shadow Term

Ray Casting Trace Primary Rays from Camera o Direct illumination from unblocked lights only

Recursive Ray Tracing Also Trace Secondary Rays from Hit Surfaces o Global illumination from mirror reflection and transparency

Mirror Reflection Trace Secondary Ray in Direction of Mirror Reflection o Evaluate radiance along secondary ray and include it into illumination model Radiance for mirror reflection ray

Transparency Trace Secondary Ray in Direction of Refraction o Evaluate radiance along secondary ray and include it into illumination model Radiance for refraction ray

Transparency Transparency coefficient is fraction transmitted o K T = 1 if object is translucent, K T = 0 if object is opaque o 0 < K T < 1 if object is semi-translucent Transparency Coefficient

Refractive Transparency For Thin Surfaces, Can Ignore Change in Direction o Assume light travels straight through surface

Refractive Transparency For Solid Objects, Apply Snell’s Law: o  r sin  r  i  sin  i

Summary Direct Illumination o Ray casting o Usually use simple analytic approximations for light source emission and surface reflectance Global illumination o Recursive ray tracing o Incorporate shadows, mirror reflections, and pure refractions

Illumination Terminology Radiant power [flux] (Φ) o Rate at which light energy is transmitted (in Watts). Radiant Intensity (I) o Power radiated onto a unit solid angle in direction( in Watt/sr)  e.g.: energy distribution of a light source (inverse square law) Radiance (L) o Radiant intensity per unit projected surface area( in Watts/m 2 sr)  e.g.: light carried by a single ray (no inverse square law) Irradianc (E) o Incident flux density on a locally planar area (in Watts/m 2 ) Radiosity (B) o Exitant flux density from a locally planar area ( in Watts/m 2 )

Thank you Next Lecture: Rendering