appearance-modeling

advertisement
Basic Principles of Surface Reflectance
Lecture #3
Thanks to Shree Nayar, Ravi Ramamoorthi, Pat Hanrahan
Computer Vision: Building Machines that See
Lighting
Camera
Physical Models
Computer
Scene
We need to understand the relation between
the lighting, surface reflectance and medium and the image of the scene.
Surface Appearance
sensor
source
normal
surface
element
Image intensities = f ( normal, surface reflectance, illumination )
Surface Reflection depends on both the viewing and illumination direction.
BRDF: Bidirectional Reflectance Distribution Function
source
z
incident
direction

(i , i )
y
viewing
direction
(r , r )
normal

surface
element
x
E surface( i , i ) Irradiance at Surface in direction (i , i )
Lsurface( r , r )
BRDF : f
Radiance of Surface in direction
( i , i ;  r , r ) 
(r ,r )
Lsurface( r , r )
E surface( i , i )
Important Properties of BRDFs
source
z
incident
direction

(i , i )
viewing
direction
(r , r )
normal
y

surface
element
x
• Rotational Symmetry:
Appearance does not change when surface is rotated about the normal.
BRDF is only a function of 3 variables :
f (i ,  r , i  r )
• Helmholtz Reciprocity: (follows from 2nd Law of Thermodynamics)
Appearance does not change when source and viewing directions are swapped.
f (i , i ;  r , r ) 
f ( r , r ; i , i )
Derivation of the Scene Radiance Equation – Important!
From the definition of BRDF:
Lsurface( r , r )  E surface( i , i ) f ( i , i ;  r , r )
Write Surface Irradiance in terms of Source Radiance:
surface
L
( r , r )  L ( i , i ) f ( i , i ;  r , r ) cos  i di
src
Integrate over entire hemisphere of possible source directions:
src
L
 (i ,i ) f (i ,i ;  r ,r ) cosi di
Lsurface( r , r ) 
2
Convert from solid angle to theta-phi representation:
Lsurface( r , r ) 
  /2


src
L
 (i ,i ) f (i ,i ; r ,r ) cosi sin i di di
0
Differential Solid Angle and Spherical Polar Coordinates
Mechanisms of Surface Reflection
source
incident
direction
surface
reflection
body
reflection
surface
Body Reflection:
Diffuse Reflection
Matte Appearance
Non-Homogeneous Medium
Clay, paper, etc
Surface Reflection:
Specular Reflection
Glossy Appearance
Highlights
Dominant for Metals
Image Intensity = Body Reflection + Surface Reflection
Mechanisms of Surface Reflection
Body Reflection:
Diffuse Reflection
Matte Appearance
Non-Homogeneous Medium
Clay, paper, etc
Many materials exhibit both Reflections:
Surface Reflection:
Specular Reflection
Glossy Appearance
Highlights
Dominant for Metals
Diffuse Reflection and Lambertian BRDF
source intensity I
incident
direction
s
normal
n
i
viewing
direction
v
surface
element
• Surface appears equally bright from ALL directions! (independent of
• Lambertian BRDF is simply a constant :
• Surface Radiance :
f ( i , i ;  r , r ) 
d
L
I cos  i

• Commonly used in Vision and Graphics!

d
I n.s

v)
d

source intensity
albedo
Diffuse Reflection and Lambertian BRDF
White-out Conditions from an Overcast Sky
CAN’T perceive the shape of the snow covered terrain!
CAN perceive shape in regions
lit by the street lamp!!
WHY?
Diffuse Reflection from Uniform Sky
Lsurface( r , r ) 
  /2


src
L
 (i ,i ) f (i ,i ; r ,r ) cosi sin i di di
0
• Assume Lambertian Surface with Albedo = 1 (no absorption)
f ( i , i ;  r , r ) 
1

• Assume Sky radiance is constant
Lsrc ( i , i )  Lsky
• Substituting in above Equation:
Lsurface( r , r )  Lsky
Radiance of any patch is the same as Sky radiance !! (white-out condition)
Specular Reflection and Mirror BRDF
source intensity I
incident
direction
(i , i )
s
normal
specular/mirror
direction
r (r ,r )
n
viewing
direction
surface
element
v (v , v )
• Very smooth surface.
• All incident light energy reflected in a SINGLE direction. (only when
• Mirror BRDF is simply a double-delta function :
specular albedo
f (i , i ; v , v )   s  (i   v )  (i    v )
• Surface Radiance :
L  I  s  (i   v )  (i    v )
v
=
r
)
BRDFs of Glossy Surfaces
• Delta Function too harsh a BRDF model
(valid only for polished mirrors and metals).
• Many glossy surfaces show broader highlights in addition to specular reflection.
• Example Models : Phong Model (no physical basis, but sort of works (empirical))
Torrance Sparrow model (physically based) – Next Class
Phong Model: An Empirical Approximation
• An illustration of the angular falloff of highlights:
L  I  s (cos  )
nshiny
• Very commonly used in Computer Graphics
Phong Examples
• These spheres illustrate the Phong model as lighting
• direction and nshiny are varied:
All components of Surface Reflection
A Simple Reflection Model - Dichromatic Reflection
Observed Image Color = a x Body Color + b x Specular Reflection Color
Klinker-Shafer-Kanade 1988
R
Color of Source
(Specular reflection)
Does not specify any specific model for
Diffuse/specular reflection
B
G
Color of Surface
(Diffuse/Body Reflection)
Separating Diffuse and Specular Reflections
Observed Image Color = a x Body Color + b x Specular Reflection Color
R
Color of Source
(Specular reflection)
G
Color of Surface
(Diffuse/Body Reflection)
B
Dror, Adelson, Wilsky
Download