Unit 6
Unit 6
and
3
Light Source
• Object that radiates energy are called light sources, such as
sun, lamp, bulb, fluorescent tube etc.
• Sometimes light sources are referred as light emitting object
and light reflectors. Generally light source is used to mean an
object that is emitting radiant energy e.g. Sun.
4
Light Source..
Point Source:
Point source is the simplest light emitter e.g. light bulb.
when light source model is a reasonable approximation for sources
whose dimensions are small compared to the size of objects in a
scene.
5
Reflection of light:
When light is incident on opaque surface part of it is
reflected and part of it is absorbed.
∴ I = A+R
• The amount of incident light reflected by a surface depends
on the type of material. Shining material reflects more
6
Distributed light source
7
Light Source..
• Point source: Simplest model for a light emitter like tungsten
filament bulb
• Distributed light source: The area of the source is not small
compared to the surfaces in the scene like fluorescent light on
any object in a room
8
Illumination models:
Illumination models are used to calculate light intensities
that we should see at a given point on the surface of an object.
Lighting calculations are based on the optical properties of
surfaces, the background lighting conditions and the light source
specifications. All light sources are considered to be point
9
Some useful concept
I=Ka
Where I is the resulting intensity and Ka is the object’s intrinsic 13
intensity.
1. Ambient light …
• If we assume that ambient light impinges equally on all
surface from all direction, then
I = Ia Ka
15
2. Diffuse Reflection…
• Illuminating object by a point light source, whose rays
enumerate uniformly in all directions from a single point. The
object's brightness varies form one part to another, depending
on the direction of and distance to the light source.
• Color of an object is determined by the color of the diffuse
16
2. Diffuse Reflection…
The diffuse-reflection coefficient, or diffuse reflectivity,
kd (varying from 0 to 1) define the fractional amount of the
incident light that is diffusely reflected.
The parameter kd (actually function of surface
color)depends on the reflecting properties of material so for
17
2. Diffuse Reflection…
If N is the unit normal vector to a surface and L is the unit
direction vector to the point light source from a position on the
surface then cos θ = N.L ( Lambertian Cosine Law) and the diffuse
reflection equation for single point source illumination is:
19
Lambert’s Cosine Law:
The intensity of diffuse reflection due to ambient light is;
Iadiff = kaIa
The radiant energy from any small surface dA in any direction relative
to surface normal is proportional to cos 𝜃. That is, brightness depends only on
the angle θ between the light direction L and the surface normal N.
∴ Light intensity α cos 𝜃.
∴ Total diffuse reflection (Idiff) = Diff ( due to ambient light)+Diff. due to pt.source.
Idiff = Iadiff + Ιpdiff 20
Idiff = kaIa + kdΙl (Ν ∙L)
3. Specular reflection and phong model
• When we look at an illuminated shiny surface, such as
polished metal, a person's forehead, we see a highlight or
bright spot, at certain viewing direction. Such phenomenon is
called specular reflection.
• It is the result of total or near total reflection of the incident
21
Nipun Thapa (Computer Graphics)
22
3. Specular reflection and phong model
Let SR angle = angle of incidence as in
figure.
N- unit vector normal to surface at
incidence point
R- unit vector in the direction of
So,
I spec = Ks IL cosns Ø
= Ks IL (V.R)ns since cosØ = V.R 26
3. Specular reflection and phong model
37
Polygon Rendering Method
(Surface Shading Method)
• Objects usually polygon-mesh approximation
• Illumination model is applied to fill the interior of polygons
• Curved surfaces are approximated with polygon meshes
• But polyhedra that are not curved surfaces are also modeled with
polygon meshes
41
2. Gouraud Shading…..
Advantages:
Removes discontinuities of intensity at the edge
compared to constant shading model