Download as pdf or txt
Download as pdf or txt
You are on page 1of 8

2022-11-25

Light reflection I
Computer Graphics Types of reflections

Dariusz Sawicki a) b) c) d) e)

Local illumination problem a) Perfect Specular (theoretical), b) Real Specular,


c) Reverse, d) Perfect (Lambert’s) Diffuse (theoretical)
– light reflection modeling e) Complete real reflection

CG Local illumination problem 4

Introduction Light reflection II

● Light – material’s surface interaction


● Geometry of reflection and refraction
● Simple Phong model of reflection
● Basic photometry units
● BRDF – Bidirectional Reflectance Distribution Function
● Examples of reflection models
● Smoothing / shading – color interpolation
• Bibliography
Ideal specular Ideal (Lambert’s) diffuse Complete
(theoretical) (theoretical) (real specular
+ real diffuse)

CG Local illumination problem 2 CG Local illumination problem 5

Light – Material’s Surface Interaction The geometry of vectors in reflection


Reflection and refraction

What influence the interaction : - normal vector to the surface in reflection point,
- vectors to observer and source of light, respectively,
• (Physical) Material properties (metal or dielectric)
- perfect specular reflection vector,
• (Geometrical) Surface properties (processing, completing)
- vector that bisects the angle between and
CG Local illumination problem 3 CG Local illumination problem 6

1
2022-11-25

Perfect specular reflection The set of vectors used in reflection


– calculation of direction modeling II
Anisotropy
Law of reflection:
angle of the outgoing light equals to the angle of the incoming
light and the incoming beam, outgoing beam and the surface
normal are in a single plane.

V - N cosθ V - N cosθ
- normal vector to the surface in reflection point,
V
N cosθ
L
V = L - 2Ncos α - vectors to observer and source of light, respectively,
θ θ - vector that bisects the angle between and
- surface orientation vector,
- unit projection of onto tangent plane in reflection point
CG Local illumination problem 7 CG Local illumination problem 10

Perfect specular refraction


Simple Phong model of reflection I
– calculation of direction
Snellius-Descartes
law of refraction :
N
sin θ I – reflected light
L - Ncosθ n=
sin θt Ia – ambient light (in object environment)
L θ N⊥ IP – light of point source
N⊥ sinθ
ka – material’s ambient-reflection coefficient
ks – material’s specular-reflection coefficient
θt - Ncosθt − L + Ncosθ
N⊥ = kd – material’s diffuse-reflection coefficient
sinθ
fatt – attenuation coefficient (distance attenuation)
V
n – smoothness factor of the material’s surface

V = N (cosθ/n - √ (1- (1- cos2 θ)/n2) ) - L/n


CG Local illumination problem 8 CG Local illumination problem 11

The set of vectors used in reflection


Simple Phong model of reflection II
modeling I
Properties of the function f (α) = cosn(α)

n=2

n=20

n=500

- normal vector to the surface in reflection point,


- vectors to observer and source of light, respectively,
- perfect specular reflection vector, α

- vector that bisects the angle between and Perfect reflection : n –> infinity
CG Local illumination problem 9 CG Local illumination problem 12

2
2022-11-25

Simple Phong model of reflection III Basic photometry units II

n=5 n=10 n=100


• (Luminous) Radiant intensity I is the luminous
ks=0,25, kd=0,75 (radiant) flux Φ radiated from a point light source into
a unit solid angleω in a particular direction. And it is
measured in watt per steradian [candela].
ks=0,5, kd=0,5


[cd ]
ks=0,75, kd=0,25
I=

Spheres illuminated by point light source

CG Local illumination problem 13 CG Local illumination problem 16

Basic photometry units I Basic photometry units II

• Radiant flux is the measure of the total power of • (Luminous) Radiant intensity I is the luminous
electromagnetic radiation (not only visible light !). It (radiant) flux Φ radiated from a point light source into
may be the total emitted from a source, or the total a unit solid angleω in a particular direction. And it is
received by surface. measured in watt per steradian [candela].

• Luminous flux is the measure of the power of


electromagnetic radiation concerning visible light.

Visible part of radiant flux. Measured in lumen [lm] I= [cd ]

Polish name: światłość


CG Local illumination problem 14 CG Local illumination problem 17

Basic photometry units I Basic photometry units III

• Radiant flux is the measure of the total power of • Irradiance (illuminance) is the luminous flux per
electromagnetic radiation (not only visible light !). It unit area incident on a surface.
may be the total emitted from a source, or the total Irradiance is sometimes referred to as the radiant
received by surface. (luminous) incidence.
( Unit for description of illumination ! )

• Luminous flux is the measure of the power of


electromagnetic radiation concerning visible light. dΦ  lm 
E= lx = 2 
dS 
Visible part of radiant flux. Measured in lumen [lm]
m 

Polish name: strumień świetlny


CG Local illumination problem 15 CG Local illumination problem 18

3
2022-11-25

Basic photometry units III Basic photometry units V

• Irradiance (illuminance) is the luminous flux per • Radiance (luminance) L is the intensity I per unit
unit area incident on a surface.
area dS’ leaving a surface. Per unit area perpendicular
Irradiance is sometimes referred to as the radiant
to the radiation direction.
(luminous) incidence.
( Unit for description of illumination ! ) dI dI
L= =
ϕ
Φ dS' dS ⋅ cos( ϕ )
dΦ  lm  Projekted
E= lx = 2  area

dS  m  dS’=dScosϕ
d 2Φ  cd 
=
dS dS ⋅ dω ⋅ cos( ϕ )  m 2 
Polish name: natężenie napromienienia
CG Local illumination problem 19 CG Local illumination problem 22

Basic photometry units IV Basic photometry units V

• Luminous (Radiant) exitance is the luminous flux • Radiance (luminance) L is the intensity I per unit
per unit area leaving a surface.
area dS’ leaving a surface. Per unit area perpendicular
( Unit for description of emission ! )
to the radiation direction.
In computer graphics, luminous/radiant exitance is often dI dI
referred to as the radiosity L= =
ϕ
Φ dS' dS ⋅ cos( ϕ )
dΦ  lm  Projekted
M= lx = 2  area

dS  m  dS’=dScosϕ
d 2Φ  cd 
=
dS dS ⋅ dω ⋅ cos( ϕ )  m 2 
Polish name: luminancja świetlna
CG Local illumination problem 20 CG Local illumination problem 23

Basic photometry units IV Basic photometry units VI

• Luminous (Radiant) exitance is the luminous flux • Radiance can be leaving, passing through, or arriving
per unit area leaving a surface. at a point on a surface.
( Unit for description of emission ! )
( Unit for description of emission and illumination ! )
In computer graphics, luminous/radiant exitance is often
referred to as the radiosity Φ Φ

dΦ  lm  ϕ ϕ
M= lx = 2 
dS  m 
dS dS

Arriving radiance Leaving radiance


Polish name: egzytancja świetlna
CG Local illumination problem 21 CG Local illumination problem 24

4
2022-11-25

Lambert’s Cosine Law I BRDF I

Bidirectional Reflectance Distribution Function (BRDF)


• The reflected luminous intensity in any direction from a is defined as:
perfectly diffusing surface varies as the cosine of the
angle between the direction of incident light and the
normal vector of the surface.
• Intuitively: cross-sectional area of
the “beam” intersecting an element where is the radiance
of surface area is smaller for greater leaving the surface (observed
angles with the normal. / θ
S SA /cos from direction )
and is the irradiance

Φ Φ cos θ Φ arriving the surface from


E= = direction
S cos θ S θ BRDF is dimensionless but is
expressed as 1 sr
CG Local illumination problem 25 CG Local illumination problem 28

Lambert’s Cosine Law II BRDF II

• Reflection:
– Ideally diffuse surfaces obey cosine law. Applied BRDF should fulfill the physical laws to describe
• Emission: the phenomena :
– Ideally emitted surface (black body) obey cosine law.
• The Helmholtz Reciprocity Rule : BRDF should be
symmetric ρ ρ ρ ρ
Practically Lambert’s Cosine Law is described as an f ( L ,V ) = f ( V , L )
equation of radiant intensity:
• The Energy Conservation Law : reflected energy
I = I MAX ⋅ cos( θ ) cannot exceed incoming energy

CG Local illumination problem 26 CG Local illumination problem 29

Why do we need radiance? Selected (!!!) reflection models

• Minnaert (1941)
• Phong (1975)
• Response of a photosensor (human eye or camera)
• Blinn/Phong (1977)
is proportional to the radiance • Cook-Torrance-Sparrow(1981)
• Kajiya (1985)
• Poulin-Fournier (1990)
• He-Torrance-Sillion-Greenberg(1991)
• Ward (1992)
• Lafortune (1994)
• Lewis/Phong (1994)
• Oren-Nayar (1994)
• We would like to analyze pixel values in the image
• Schlick (1994)
as proportional to radiance received from that
• Embrechts (1995)
direction. • Koenderink - van Doorn (1998)
• Neumann-Neumann-Szirmay-Kalos (1999)
• Ashikhmin-Shirley (2000)
CG Local illumination problem 27 CG Local illumination problem 30

5
2022-11-25

Torrance-Sparrow model of surface Cook-Torrance (1981 r.) III

D is the Beckmann distribution function (used by Cook


• Phenomenological vs. physical BRDFs and Torrance) as the most suitable for the polyhedral
character of the surface roughness for different
• Assumptions for the physics based models: materials:
– Diffuse component comes from multiple reflections  tg 2 β 
− 2 
1
D= ⋅ e  B 
between faces and from internal scattering. m

– Specular component of surface comes from faces 4 mB cos β


2 4

oriented in direction of H.
N
L
H
V mB(0, 1) is the parameter that characterizes the
smoothness of surface - the smaller value, the closer
l
reflection to the perfect directional one
m
l

CG Local illumination problem 31 CG Local illumination problem 34

Cook-Torrance (1981 r.) I Microfacet distribution function

This model was worked out on the basis of theoretical works Phong
of Torrance and Sparrow concerning the physical description Beckmann
of smoothness (roughness) of the surface as well as on the Trowbridge-Reitz
Blinn’s considerations. Specular reflection in this model is Gauss
described as Schlick

where
F (θH) — the Fresnel reflectivity factor (Fresnel function)
G — geometrical factor describes attenuation (shadowing
and masking) of the surface microelements
D — microfacet distribution function describes dependence
The Graphs of different distribution functions (normalized)
of light reflection on surface roughness
CG Local illumination problem 32 CG Local illumination problem 35

Cook-Torrance (1981 r.) II Fresnel reflectivity factor

G — geometrical factor describes attenuation


(shadowing and masking) of the surface microelements
N Fresnel reflectivity factor aluminum
gold
L
H (Fresnel function) describes diamond
glass

V
the reflection dependence
on an angle of incidence
and on a length of wave .

 m
G = min1, 1 − 
l
m
l
 l
Schlick introduced very Fresnel reflectivity factor for
effective approximation selected materials

F (θ ) = F0 + (1 − F0 ) ⋅ (1 − cos(θ )) 5
CG Local illumination problem 33 CG Local illumination problem 36

6
2022-11-25

Ashikhmin-Shirley model (2000 r.) Smoothing / shading

This is an extension of the Phong model, but it fulfills the


Helmholtz Reciprocity Rule and the Energy Conservation
Law. This model also takes into account the anisotropy of
reflection as well as the Fresnel reflectivity factor. Specular
reflection in this model is described by equation wygładzanie
smooth

obserwator
observer obserwator
observer
where p = nu ⋅ cos 2 φ + nv ⋅ sin 2 φ , nu and nv coefficients
(Phong like) describes smoothness independently along
the suitable perpendicular directions on the surface. In polygonal data there exists smoothness need
— need of color interpolation.
CG Local illumination problem 37 CG Local illumination problem 40

Comparison of selected reflection


Gauraud shading / interpolation
models (specular part)
Color in point E is expected.
It is calculated „directly”.
y IB
B
IC
yB − y D y − yA
ID = I A ⋅ + IB ⋅ D
C yB − y A yB − y A
D E
yC − y F y − yA
F
IF = IA ⋅ + IC ⋅ F
yC − y A yC − y A
A
IA
xF − xE x − xD
x IE = ID ⋅ + IF ⋅ E
xF − xD xF − xD

Graphs of normalized BRDF (for real specular reflection) of the different


models for angle of incidence : 15o, 30o, 45o, 60o

CG Local illumination problem 38 CG Local illumination problem 41

Other methods of reflection describing Phong shading / interpolation


Color in point E is expected.
y NB It is calculated „indirectly”.
B
• Layer models NC Normal vector in point E is determined.
C

• Measured BRDF – tables of factors for different materials, ND NE


surface properties and angles E NF
D F
NA
• Spherical harmonics A
x

Color in point E ic calculated using (interpolated) normal


vector and proper reflection model.
CG Local illumination problem 39 CG Local illumination problem 42

7
2022-11-25

Smoothing / shading – differences

Highlights problem

a) b) c) d)

a. polygonal model c. Gouraud shading


b. flat (polygonal) shading d. Phong shading

CG Local illumination problem 43

Smoothing / shading
– calculation problems
0 1
• Orientation influence
1 1
– Scanline interpolation
0 0
depends on position
(rotation) of the object 1 0
0 1

• Influence of the
norepresentative normal
vectors
– Position of the
neighboring face can
change color

CG Local illumination problem 44

Bibliography (additionally)

• Hall R.: Illumination and Color in Computer Generated


Imagery, Springer-Verlag, 1989.
• Dutré Ph.: Global Illumination Compedium. The Concise
Guide to Global Illumination Alhgorithms, September
2003, http://www.cs.kuleuven.ac.be/~phil/GI/
• CUReT, Columbia-Utrecht Reflectance and Texture
Database,
http://www1.cs.columbia.edu/CAVE/software/curet/index.php
• Measured BRDF data from Cornell University,
http://www.graphics.cornell.edu/online/measurements/
• Pharr M., Humphreys G.: Physically Based Rendering,
from Theory to Implementation, 3rd ed. Morgan Kaufmann
2016.
CG Local illumination problem 45

You might also like