Lecture 17 Materials and Appearances¶
Material = BRDF¶
Diffuse / Lambertian Material¶
Light is equally reflected in each output direction
Suppose the incident lighting is uniform(均匀的)and diffuse \(\to\) 入射的 Irradiance= 出射的 Irradiance \(\to\) 入射的 radiance= 出射的 radiance
这样就可以写出渲染方程,没有自己发光项
简化渲染方程,假设入射的 radiance 为常数,BRDF 为常数,结果就是对半球上的一个 \(\cos\theta\) 函数的积分 \(\to \ \pi\)
由于能量守恒,入射的 radiance= 出射的 radiance,即 \(L_i = L_o\),所以有
- albedo (color) [反射率,可以引入不同的颜色]
Glossy material (BRDF)¶
Ideal reflective / refractive material (BSDF*)¶
- 双向散射分布函数 (Bidirectional scattering distribution function)
Specular Refraction¶
Perfect Specular Reflection¶
- 性质:入射光和出射光的角平分线一定是法线
Snell’s Law¶
- 也叫折射定律
- Transmitted angle depends on
- index of refraction (IOR) for incident ray
- index of refraction (IOR) for exiting ray
Law of Refraction¶
- 折射不可能发射的情况:When light is moving from a more optically dense medium to a less optically dense medium (i.e. \(\frac{\eta_i}{\eta_t}>1\)) Light incident on boundary from large enough angle will not exit medium.
Fresnel Reflection / Term¶
- reflectance increases with grazing angle
Fresnel Term — Formulae¶
- Accurate: need to consider polarization 考虑光的两个极化
再取它们的平均即可,即
-
Approximate: Schlick’s approximation
- 对刚刚的精确公式拟合一个曲线,设基准反射率为 \(R_0\)
Microfacet Material¶
- Name: 微表面模型
- 观察者从远处看的时候,看到的粗糙表面成为平的表面,看到的是材质
- 观察者从近处看的时候,看到的是几何
Rough surface
- Macroscale: flat & rough
- Microscale: bumpy & specular
Individual elements of surface act like mirrors (每一个微表面可以认为是镜面)
- Known as Microfacets
- Each microfacet has its own normal
Microfacet BRDF¶
- Key: the distribution of microfacets’ normals
- 通过微表面模型,可以把表面的粗糙程度用表面的法线分布表示
- \(F(i,h)\): 表示菲涅尔项,总共有多少能量被反射
- \(G(i,o,h)\): 几何项,微表面可能互相遮挡(自己给自己的阴影)导致有一些微表面失去了它的作用
- 光方向与物体表面几乎平行的时候最明显,Grazing Angel
- \(D(h)\): 表示微表面的法线分布,因为每一个微表面都可以认为是镜面,只有半程向量和法线垂直的微表面能够将光反射到出射方向
Isotropic / Anisotropic Materials (BRDFs)¶
-
Isotropic 各向同性:微表面不存在方向性或者方向性很弱
-
Anisotropic 各向异性:微表面存在方向性
-
识别:BRDF 在方位上旋转得到相同的 BRDF
-
Reflection depends on azimuthal angle \(\phi\)
\[ f_r\left(\theta_i, \phi_i ; \theta_r, \phi_r\right) \neq f_r\left(\theta_i, \theta_r, \phi_r-\phi_i\right) \]- Example
-
Properties of BRDFs¶
- Non-negativity
- Linearity 线性性质(可以加起来)
- Reciprocity principle 可逆性(交换入射方向和出射方向的角色,得到的 BRDF 相同)
- Energy conservation 能量守恒
- 在 Path Tracing 时经过无限次的光线弹射,最后的光线收敛就是因为能量守恒
-
Isotropic vs. anisotropic
-
If isotropic, \(f_r\left(\theta_i, \phi_i ; \theta_r, \phi_r\right)=f_r\left(\theta_i, \theta_r, \phi_r-\phi_i\right)\)
-
各向同性意味着 BRDF 之和相对的方位角有关,实际上此时 \(f_r\) 为三维
-
Then, from reciprocity,
-
相对的方位角不用考虑正负 \(\to\) BRDF 的测量与储存
\[ f_r\left(\theta_i, \theta_r, \phi_r-\phi_i\right)=f_r\left(\theta_r, \theta_i, \phi_i-\phi_r\right)=f_r\left(\theta_i, \theta_r,\left|\phi_r-\phi_i\right|\right) \] -
Measuring BRDFs¶
Measuring BRDFs: Motivation¶
Avoid need to develop / derive models - Automatically includes all of the scattering effects present
Can accurately render with real-world materials
- Useful for product design, special effects, ...
Image-Based BRDF Measurement¶
- Algorithm
for each outgoing direction wo
move light to illuminate surface with a thin beam from wo
for each incoming direction wi
move sensor to be at direction wi from surface
measure incident radiance
Improving efficiency: - Isotropic surfaces reduce dimensionality from 4D to 3D - Reciprocity reduces # of measurements by half - Clever optical systems... (例如猜出来)
Challenges in Measuring BRDFs¶
- Accurate measurements at grazing angles
- Important due to Fresnel effects
- Measuring with dense enough sampling to capture high frequency specularities
- Retro-reflection
- Spatially-varying reflectance, ...
Representing Measured BRDFs¶
Desirable qualities - Compact representation - Accurate representation of measured data - Efficient evaluation for arbitrary pairs of directions - Good distributions available for importance sampling
Tabular Representation¶
Store regularly-spaced samples in \(\( \left(\theta_i, \theta_o,\left|\phi_i-\phi_o\right|\right) \)\) - Better: reparameterize angles to better match specularities
Created: June 16, 2023