Class 07 Optics

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

Optics

Solid Angle
• A 2D angle in 3D, defined by a point and a surface patch (measured in steradians)
𝑙𝑎𝑟𝑐 𝐴𝑜𝑛 𝑡ℎ𝑒 𝑠𝑝ℎ𝑒𝑟𝑒 𝑠𝑢𝑟𝑓𝑎𝑐𝑒
• Angles have 𝜃 = , and solid angles have 𝜔 =
𝑟 𝑟2
• Circumference of a circle is 𝐶 = 2𝜋𝑟, so a circle has 2𝜋 radians
• Surface area of a sphere is 4𝜋𝑟 2 , so a sphere has 4𝜋 steradians
Radiant Intensity from a Light Source
𝑑𝛷
• Power per unit solid angle 𝐼 𝜔 =
𝑑𝜔
• 𝛷 is the light source power (in watts = joules per second)
• Anisotropic light source: 𝐼 varies across the light (as a function of 𝜔)
• Isotropic point light: integrate 𝑑𝛷 = 𝐼𝑑𝜔 to obtain 𝛷 = ‫𝑝𝑠׬‬ℎ𝑒𝑟𝑒 𝐼𝑑𝜔 = 4𝜋𝐼

anisotropic light source isotropic point light


Irradiance onto a Surface
𝑑𝛷
• Power per unit surface area 𝐸 =
𝑑𝐴
𝐴𝑐𝑜𝑠𝜃
𝛷𝑓𝑙𝑎𝑡 𝛷𝑓𝑙𝑎𝑡
• Given 𝐸𝑓𝑙𝑎𝑡 = , note that 𝐸𝑡𝑖𝑙𝑡𝑒𝑑 = 𝐴
= 𝐸𝑓𝑙𝑎𝑡 𝑐𝑜𝑠𝜃
𝐴 𝐴
• Irradiance decreases as you tilt the surface, since less photons hit per unit surface area
Solid Angle vs. Cross-Sectional Area
• The (orthogonal) cross-sectional area is 𝑑𝐴 𝑐𝑜𝑠𝜃 (from the previous slide)
𝑑𝐴𝑠𝑝ℎ𝑒𝑟𝑒 𝑑𝐴 𝑐𝑜𝑠𝜃
• So, 𝑑𝜔 = = (so, the solid angle varies with the tilt 𝜃 and the distance 𝑟)
𝑟2 𝑟2

S0
unit
sphere
d

r N̂


surface
patch
dA
Area Lights
• Light power is emitted per unit area (not from a single point)
• The emitted light goes in various directions (measured with solid angles)

• Break an area light up into (infinitesimally) small area chunks


• Each area chunk emits light into each of the solid angle directions
• i.e. radiant intensity per area chunk
• Each emitted direction also has a cosine term (similar to irradiance)

• Radiance – radiant intensity per area chunk


𝑑𝐼 𝑑2Φ 𝑑𝐸
𝐿= = =
𝑑𝐴 cos𝜃𝑙𝑖𝑔ℎ𝑡 𝑑𝜔 𝑑𝐴 cos𝜃𝑙𝑖𝑔ℎ𝑡 𝑑𝜔 cos𝜃𝑙𝑖𝑔ℎ𝑡
Objects act as Area Lights
• Light comes from all visible objects in the world (not just from light sources)
• Each area chunk of each object acts as a source of light (i.e. as a light source)

• A tree “shines” light onto the car; then, the car “shines” light onto the camera:
Objects act as Area Lights
• The red paper “shines” red light onto the statue (color bleeding); then, the statue “shines” red
light onto the camera:
Objects act as Area Lights
• It’s not good enough to only look for light along shadow rays (even though, it’s pretty good)

using light only from shadow rays using light from shadow rays and objects
Measuring Incoming Light
• Light Probe: a small reflective chrome sphere
• Photograph it, in order to record the incoming light (at its location) from all directions
Using the Measured Incoming Light
• The measured incoming light can be used to render a synthetic object with realistic lighting
Light/Object Interactions
• When light hits a material, it may be: absorbed, reflected, transmitted
• As light passes through a material, it may be: absorbed, scattered
• When exits a material, it may be: absorbed, reflected, transmitted
Engineering Approximations
• BRDF
• Bidirectional Reflectance Distribution Function
• models how light is reflected
• BTDF
• Bidirectional Transmittance Distribution Function
• models how light is transmitted
• BSSRDF
• Bidirectional Surface Scattering Reflectance
Distribution Function
• combined reflection/transmission model
Opaque (BRDF) vs. Translucent (BSSRDF)
Opaque (BRDF) vs. Translucent (BSSRDF)
Opaque (BRDF) vs. Translucent (BSSRDF)
Opaque (BRDF) vs. Translucent (BSSRDF)
BRDF
• 𝐵𝑅𝐷𝐹(𝜆, 𝜔𝑖 , 𝜔𝑜 , 𝑢, 𝑣)
• 𝜆 is the wavelength (we’ll cheat with R, G, B as usual)
• 𝑢, 𝑣 are the coordinates on the object’s surface (we’ll cheat with a texture)
• 𝜔𝑖 (𝜃𝑖 , 𝜙𝑖 ) and 𝜔𝑜 (𝜃𝑜 , 𝜙𝑜 ) are the incoming/outgoing light directions
• Each parameterized via the 2D surface of a hemisphere: 𝜃 and 𝜙 in polar corrdinates

• Consider: 𝐵𝑅𝐷𝐹𝑅 (𝜔𝑖 , 𝜔𝑜 ), 𝐵𝑅𝐷𝐹𝐺 (𝜔𝑖 , 𝜔𝑜 ), 𝐵𝑅𝐷𝐹𝐵 (𝜔𝑖 , 𝜔𝑜 )


• Each is a 4D function, i.e. functions of 4 variables 𝜃𝑖 , 𝜙𝑖 , 𝜃𝑜 , 𝜙𝑜

𝑑𝐿𝑜 𝜔𝑜
• Specifically: 𝐵𝑅𝐷𝐹 𝜔𝑖 , 𝜔𝑜 =
𝑑𝐸𝑖 (𝜔𝑖 )
• The outgoing light emitted from a surface patch (acting as an area light), as a
fraction of the incoming light hitting that surface patch (irradiance)
Measuring and Approximating BRDFs
• Can measure 4D BRDF data with a
gonioreflectometer (to obtain a 4D table of values)

• Engineering Approximations:
• Blinn-Phong Model – simplest and general purpose
(plastic)
• Cook-Torrance Model – better specular (metal)
• Ward Model – anisotropic (brushed metal, hair)
• Oren-Nayar Model – non-Lambertian (concrete, plaster,
the moon)
• Etc.
The Lighting Equation
• Given a point on an object:
• Light from every incoming direction 𝜔𝑖 hits that point
• For each incoming direction 𝜔𝑖 , light is reflected outwards in every direction 𝜔𝑜
• The BRDF indicates what fraction of the light from an incoming direction 𝜔𝑖 is reflected in
each of the outgoing directions 𝜔𝑜

• Light is reflected in all outgoing directions (allowing us all to see the same spot on
an object)
• But, we all see different light (so it can, and often does, look differently to each
one of us)
• To render a synthetic scene, just need to figure out what light each pixel of the
camera’s film sees
It’s an Integral
• The total amount of light reflected in a single outgoing direction is the sum of the
of the light reflected in that direction due to light incoming from every direction:
𝐿𝑜 (𝜔𝑜 ) = σ𝑖∈𝑖𝑛 𝐿𝑜 𝑑𝑢𝑒 𝑡𝑜 𝑖 𝜔𝑖 , 𝜔𝑜
The Lighting Equation
• For each pixel, integrate the BRDF across all incoming directions for every point in
the pixel’s un-projected area (which acts as an area light)

𝐿𝑜 (𝜔𝑜 ) = න 𝐵𝑅𝐷𝐹 𝜔𝑖 , 𝜔𝑜 𝑑𝐸𝑖 (𝜔𝑖 )


𝑖∈𝑖𝑛

All incoming directions i


pixel

o
d i
Ei
Lo
(Radiance only) Lighting Equation
• Multiplying the BRDF by an incoming irradiance gives the outgoing radiance
𝑑𝐿𝑜 𝑑𝑢𝑒 𝑡𝑜 𝑖 (𝜔𝑖 , 𝜔𝑜 ) = 𝐵𝑅𝐷𝐹 𝜔𝑖 , 𝜔𝑜 𝑑𝐸𝑖 (𝜔𝑖 )

• For even more realistic lighting, we’ll bounce light all around the scene
𝑑𝐸
• It’s tedious to convert between 𝐸 and 𝐿, so use 𝐿 = to obtain:
𝑑𝜔 cos 𝜃𝑙𝑖𝑔ℎ𝑡
𝑑𝐿𝑜 𝑑𝑢𝑒 𝑡𝑜 𝑖 (𝜔𝑖 , 𝜔𝑜 ) = 𝐵𝑅𝐷𝐹 𝜔𝑖 , 𝜔𝑜 𝐿𝑖 𝑑𝜔𝑖 cos 𝜃𝑖

• Then,

𝐿𝑜 𝜔𝑜 = න 𝐵𝑅𝐷𝐹 𝜔𝑖 , 𝜔𝑜 𝐿𝑖 cos 𝜃𝑖 𝑑𝜔𝑖


𝑖∈𝑖𝑛
Pixel Color
• Power per unit area hitting a pixel (irradiance):
obtained from integrating
𝐸𝑖 = න 𝐿𝑖 𝑐𝑜𝑠𝜃𝑖 𝑑𝜔𝑖 𝑑𝐸 = 𝐿𝑑𝜔𝑐𝑜𝑠𝜃

• Assume 𝐿 and 𝜃 are constant across the (very) small pixels:

𝐸𝑝𝑖𝑥𝑒𝑙 ≈ 𝐿𝑝𝑖𝑥𝑒𝑙,𝑎𝑣𝑒 cos 𝜃𝑝𝑖𝑥𝑒𝑙,𝑎𝑣𝑒 න 𝑑𝜔𝑖 = 𝐿𝑝𝑖𝑥𝑒𝑙,𝑎𝑣𝑒 cos 𝜃𝑝𝑖𝑥𝑒𝑙,𝑎𝑣𝑒 𝜔𝑝𝑖𝑥𝑒𝑙


𝜔𝑓𝑖𝑙𝑚
• If the film is small, cos 𝜃𝑝𝑖𝑥𝑒𝑙,𝑎𝑣𝑒 ≈ 1 and 𝜔𝑝𝑖𝑥𝑒𝑙 ≈ ; so,
# 𝑝𝑖𝑥𝑒𝑙𝑠
𝜔𝑓𝑖𝑙𝑚
𝐸𝑝𝑖𝑥𝑒𝑙 ≈ 𝐿𝑝𝑖𝑥𝑒𝑙,𝑎𝑣𝑒
# 𝑝𝑖𝑥𝑒𝑙𝑠
• Thus, can store 𝐿 instead of 𝐸 (and scale by constant later)

You might also like