Graphics16 Illumination
Graphics16 Illumination
Illumination
L ight
Green
absorbed, while green
light is reflected from
the object
8
of
50
Surface Lighting Effects
The amount of incident light reflected by a
surface depends on the type of material
Shiny materials reflect more of the incident
light and dull surfaces absorb more of the
incident light
For transparent surfaces some of the light is
also transmitted through the material
9
of
50
Diffuse Reflection
Surfaces that are rough or grainy tend to
reflect light in all directions
This scattered light is called diffuse
reflection
10
of
50
Specular Reflection
Additionally to diffuse reflection some of the
reflected light is concentrated into a highlight
or bright spot
This is called specular reflection
11
of
50
Ambient Light
A surface that is not
exposed to direct light
may still be lit up by
reflections from other
nearby objects –
ambient light
The total reflected light
from a surface is the
sum of the contributions
from light
sources and reflected
light
12
of
50
Example
13
of
50
Example
Ambient Diffuse
Final
Specular Image
14
of
50
Basic Illumination Model
We will consider a basic illumination model
which gives reasonably good results and is
used in most graphics systems
The important components are:
– Ambient light
– Diffuse reflection
– Specular reflection
For the most part we will consider only
monochromatic light
15
of
50
Ambient Light
To incorporate background light we simply
set a general brightness level for a scene
This approximates the global diffuse
reflections from various surfaces within the
scene
We will denote this value as Ia
16
of
50
Diffuse Reflection
First we assume that surfaces reflect
incident light with equal intensity in all
directions
Such surfaces are referred to as ideal
diffuse reflectors or Lambertian reflectors
17
of
50
Diffuse Reflection (cont…)
I l ,diff k d I l ,incident
k d I l cos
22
of
50
Diffuse Reflection (cont…)
Assuming we denote the
Images taken from Hearn & Baker, “Computer Graphics with OpenGL” (2004)
specular-reflection direction
Other objects exhibit specular reflections
over a finite range of viewing positions
around vector R
27
of
50
The Phong Specular Reflection Model
Exam Question
I I ambdiff I l ,diff I l , spec
Common
l 1
n
k a I a I l k d N L k s V R
ns
l 1
35
of
50
Summary
T create realistic (or even semi-realistic)
looking scenes we must model light correctly
To successfully model lighting effects we
need to consider:
– Ambient light
– Diffuse reflections
– Specular reflections