radiosity 2001.2.21 김 성 남. contents definition/goal basic radiosity method progressive...
TRANSCRIPT
RadiosityRadiosity
2001.2.21
김 성 남
ContentsContents
Definition/GoalBasic Radiosity MethodProgressive Radiosity MethodMesh substructuringHierarchical RadiosityRay Tracing and Radiosity
DefinitionDefinitionRadiosity
- method for describing diffuse reflection- We can accurately model diffuse reflecitons from a surface by considering the radiant energy transfers between surfaces → conservation of energy laws- independent on viewer
Ray Tracing Specular reflection- dependent on viewer
Radiosity- object 의 diffuse reflection 특성을 이용- light source 가 object surface 를 가질수 있음 .
Ray Tracing- object 의 specular reflection, transparency 특성을 이용- light, object surfaces 항상 분리
DefinitionDefinition
GoalGoalSimulate diffuse inter-object reflections
and shadows
Basic IdeaBasic IdeaTreat every polygon as light source
Advantages- Physically models shadows and indirect diffuse illumination- Independent of any viewpoint
Radiosity Equation- Equation Formulation
Bk : Radiosity of patch kEk : Emission of patch kρk : Reflectivity of patch kFjk : Form Factor between patch j and k
Basic Radiosity ModelBasic Radiosity Model
Bk = Ek + ρk BjFjk
n
∑j=1
Background- radian θ = s/r
- solid angle ω = A/r2
ω : steradian
Basic Radiosity ModelBasic Radiosity Model
s
r
θ
rω
A
Radiosity of patch : BBk : Radiosity of patch k
- total diffuse reflection rate of energy leaving surface k per unit area
dB : differential amount of radiant energy (joules/sec•meter2, watts/meter2)
Basic Radiosity ModelBasic Radiosity Model
xy
z
θ
ΦN
dB
dω
I : Intensity or luminance- radiant energy per unit time per unit projected area per unit solid angle (watts/meter2•steradians)
I = dB / dωcosΦassuming the surface is ideal diffuse reflector,I = constant
B = ∫hemi dB B = I ∫hemi cosΦdω
Basic Radiosity ModelBasic Radiosity ModelΦ
Φ
dA
dAcosΦ
dω = dS / r2 = sinΦdΦdθ
B = I ∫o ∫o cosΦsinΦdΦdθ = Iπ
Basic Radiosity ModelBasic Radiosity Model
xy
z
θ
ΦN
dB
dωdS
2π π/2
Enclose of surfaces for the radiosity model
Hk = BjFjk
Hk : Insident energyFjk : Form factor for surfaces j and k(fractional amount of surfaces j k)
Basic Radiosity ModelBasic Radiosity Model
∑j
Hk
Bk
Surface k
Bk = Ek + ρkHk
Basic Radiosity ModelBasic Radiosity Model
Bk = Ek + ρk BjFjk
n
∑j=1
Emission of patch : Eif surface k <> light source E = 0else rate of energy emitted from surface per unit area(watts/meter2)
Reflectivity factor of patch : ρpercent of incident light reflected in all directions
Basic Radiosity ModelBasic Radiosity Model
Form factor : Fenergy transfer from surface j to surface k
dBjdAj = (IjcosΦjdω)dAj
solid angle dω : the projection of area element dAk
perpendicular to the direction dBj
dω = dA / r2 = cosΦkdAk / r2
Basic Radiosity ModelBasic Radiosity Model
dω = dA / r2 = cosΦkdAk / r2
dBjdAj = IjcosΦjcosΦkdAjdAk / r2
Bj = πIj 이므로
Basic Radiosity ModelBasic Radiosity Model
ΦjNj
dBj
dω
Surface j
Surface k
Nk
Φk
dAj
dAkFdAj,dAk = Total energy leaving dAj
Energy incident on dAk
=IjcosΦjcosΦkdAjdAk
r2•
BjdAj
1
FdAj,dAk = πr2
cosΦjcosΦkdAk
- condition
Fjk = 1, for all k(conservation of energy)
AjFjk = AkFkj (uniform light reflection)
Fjj = 0, for all j ( assuming only plane or convex surface patches)
Basic Radiosity ModelBasic Radiosity Model
πr2
cosΦjcosΦkFdAj,Ak = dAk∫surf j
Fjk = A1 ∫surf j∫surf k πr2
cosΦjcosΦk dAkdAj
n
∑j=1
Form factor 의 계산속도 향상을 위해서
HemiSphere HemiCube(spherical surface) (linear(plane) surface)
Basic Radiosity ModelBasic Radiosity Model
HemiCube Method- project scene onto hemicube positioned at centroid of patch i- count pixel coverage to determine form factors Fi - can use H/W z-buffer → speed up → use Image precision, prone to aliasing
Basic Radiosity ModelBasic Radiosity Model
.
.
....
.
.
....
.
.
.=
(1 – ρkFk)Bk - ρk BjFjk = Ek, k =1,2,3,…,n
Matrix Formulation → Gauss-Seidel Iteration : O(n2) 1 – ρ1F11 – ρ1F12 …. – ρ1F1n B1 E1 1 – ρ2F21 1 – ρ2F22 …. – ρ2F2n B2 E2
1 – ρnFn1 – ρnFn2 …. 1 – ρnFnn Bn En
Bk = Ek + ρk BjFjk
n
∑j=1
Basic Radiosity ModelBasic Radiosity Model
Matrix Solution Methods- Gaussian elimination : O(n3)
- LU Decomposition decomposing an N x N matrix A a lower Triangular Matrix L a upper Triangular Matrix U LU = A
Basic Radiosity ModelBasic Radiosity Model
L11 0 0 U11 U12 U13 A11 A12 A13L21 L22 0 0 U22 U23 A21 A22 A23L31 L32 L33 0 0 U33 A31 A32 A33
=
Progressive RefinementProgressive RefinementGoal
- Speep up the calculation time- Reduce storage requirement
Method- initially, set Bk = Ek for all surface patches- select the patch with the highest values • store one hemicube • light source are chosen first - calculate radiosity- discard this value- next step, repeat.
Display- from dark scene to a fully illuminated one- to produce more useful initial view, can set ambient light- at each stage of iteration, reduce ambient light
Speed : O(n2)- but get pretty good solutions more quickly
Progressive RefinementProgressive Refinement
Progressive RefinementProgressive RefinementExample
Iteration 1 Iteration 2
Iteration 24 Iteration 100
Mesh SubstructuringMesh SubstructuringAdaptive subdivision
- To improve computation time for n2 form factors
partition each patch into multiple subpatch along gradients of radiosity
using the hemicubereplace more accurate area-weighted average
of the form factors from its subpatchesuntil the differences reach an acceptable levelSpeed : O(np)
- p : partition
Mesh SubstructuringMesh Substructuring
Multiresolution Computation- substructure patches into quad-tree- Transfer energy using lower resolution mesh elements if can do so within error tolerance
Speed : O(n)
Hierarchical RadiosityHierarchical Radiosity
Substructure & HierarchicalSubstructure & HierarchicalExample : using hemicube to compute form factors
Hierarchical radiosity Mesh substructuring
Dilemma- Radiosity : diffuse reflection- Ray Tracing : specular reflection
Combine
Ray Tracing and RadiosityRay Tracing and Radiosity
Ray Tracing and RadiosityRay Tracing and Radiosity
Diffuse radiosity Diffuse first pass & ray-tracing second pass
Diffuse first passwith extended
from form factors & ray tracing second pass
Example