Real-Time Global Illumination Techniques
-
Upload
jangho-lee -
Category
Technology
-
view
3.705 -
download
7
description
Transcript of Real-Time Global Illumination Techniques
![Page 2: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/2.jpg)
개요
Global Illumination 소개
Real-Time / for Games
Indirect Lighting(Inter-reflections) Techniques– SSGI, RSM, SII, IR, ISM, CLPV
토의 및 결론
![Page 3: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/3.jpg)
Global Illumination
Direct Illumination + Indirect Illumination
Offline Techniques– Radiosity– Ray Tracing– Photon Mapping
Cornell Box, 실제, 렌더링, 차이 [cu98]
![Page 4: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/4.jpg)
Local Illumination vs Global Illumination
Local Illumination Global Illumination
![Page 5: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/5.jpg)
Direct, Indirect Illumination
Direct Illumination
Direct + Indirect Illumination, Shrek2
Indirect Illumination
![Page 6: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/6.jpg)
GI Equation
x
ω r Li
θ
n
[sc09]
L
![Page 7: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/7.jpg)
Radiosity
Radiosity = 단위 시간, 단위 면적당 에너지
Patch 단위, Form Factor에 의해 면적당 에너지 계산, 누적
Diffuse-Diffuse Interaction 만 고려
Radiosity Patches Form Factor
![Page 8: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/8.jpg)
Ray Tracing
시야에서 광선 추적 (Reverse, View Dependent)
Hit Object 마다 Lighting 계산, Reflected or Refracted로 확장
Path Tracing으로 Indirect Lighting 구현 가능
Ray Tracing (Reflected, Refracted, Shadowed)
Eye
Screen
Refracted
Reflected
Shadowed
Light
![Page 9: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/9.jpg)
Photon Mapping
Light로부터 방출된 Photon 저장, Path Tracing으로 Rendering
2 Pass: Photon Tracing, Rendering
Caustics, Sub-Surface Scattering 등에 빠른 계산
Photon Visualization Rendering
![Page 10: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/10.jpg)
Real-Time?
2011년 기준 상용 하드웨어, 상용 제품– PC, XBox360, PS3
Pre-Computed + Direct Illumination이 대세
기존 GI 알고리즘의 직접 적용– 실시간 Ray Tracing은 데모 수준– 실시간 Radiosity는 단순화된 씬으로 가속, Enlighten/BF3– Offline Renderer에 도움을 주는 역할
Indirect Illumination에 특화된 적용– Diffuse Inter-reflection– 1 Bounce
![Page 11: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/11.jpg)
Lighting in Games
Static Light & Static Geometry– Lightmap
Dynamic Light & Static Geometry– PRT
Static Light & Dynamic Geometry– Irradiance Volumes (Point Light Cloud)
Dynamic Light & Dynamic Geometry– SSGI– RSM, SII– IR, ISM– CLPV
![Page 12: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/12.jpg)
SSGI
Screen Space Global Illumination [ssdo09]
SSAO(SSDO)를 Indirect Illumination으로 확장
D.I. 이후, 인접 Pixel을 간접 광원으로 사용
1 Bounce
SSAO 대비 약 30% 추가 비용– SSAO: 58fps– SSGI: 40fps– 1024 x768, N=16– nVidia 8800 GTX
SSDO SSGI
![Page 13: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/13.jpg)
SSGI
Result
![Page 14: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/14.jpg)
SSGI
SSAO와 동일한 장단점
화면 복잡도와 무관한 성능
잘못된 Occlusion: Depth, 각도
지역적: 반경 이상의 간접광 표현 못함
잘못된 Visibility: 각도 변화 잘못된 Occlusion: Depth
![Page 15: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/15.jpg)
RSM
Reflective Shadow Maps [rsm05]
Shadow Map을 Indirect Light Source로 활용
Shadow Map이므로, Light의 Occlusion을 내포
1 Light source, 1 Bounce
RSM 생성을 제외하고, 화면 복잡도와 무관, 동일한 성능
![Page 16: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/16.jpg)
RSM
Light 시점에서 RSM 생성, Depth(Position), Normal, Flux
각 픽셀을 Light Source로 간주
Depth Position Normal Flux: Bright + Color
Light 시점에서 생성된 RSM
![Page 17: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/17.jpg)
RSM
Fragment Shader(PS)에서 Indirect Illumination 계산
x의 Indirect Lighting 계산시 참조하는 RSM
모든 픽셀을 누적
![Page 18: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/18.jpg)
RSM
Gathering– Potentially Important Samples– polor 좌표계, st(uv)
월드 분포의 거리가 RSM에서의 분포와 비례 면적당 Weight
![Page 19: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/19.jpg)
RSM
Result– 9.1fps, 512 x 512, N=224, nVidia FX4000
Light 시점에서 생성된 RSM
최종 렌더링 결과
![Page 20: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/20.jpg)
Splatting Indirect Illumination
RSM을 Gathering이 아닌 Shooting [sii07]
Deferred Shading
Instant Radiosity와 유사, Occlusion이 고려되진 않음
Importance Sampling
![Page 21: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/21.jpg)
Instant Radiosity
VPL(Virtual Point Lights) 기반 [ir97][ir08]
VPL을 생성하여 Direct, Indirect Light Source로 활용
Light에서 VPL생성 VPL로부터 Illumination 계산
![Page 22: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/22.jpg)
Instant Radiosity
Result
최종 렌더링 VPL 배치
![Page 23: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/23.jpg)
Instant Radiosity
Light Occlusion– Shadow Map을 이용– 쉽지만, 비싼 비용
각 VPL당 Shadow Maps
![Page 24: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/24.jpg)
Instant Radiosity
VPL Distribution– Path Tracing와 유사– Shadow를 포함한 VPL의 누적
1차 바운스
4차 바운스
…
렌더링 결과누적
![Page 25: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/25.jpg)
Imperfect Shadow Maps
Instant Radiosity 기반 [ism08]
Indirect Lighting은 매우 부드럽게 변함
VPL의 기여도는 매우 작음
![Page 26: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/26.jpg)
Imperfect Shadow Maps
Low Quality Depth Maps로 충분– Point-Based Rendering으로 Depth Map 생성
![Page 27: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/27.jpg)
Imperfect Shadow Maps
Point-Based Depth Maps을 이용한 렌더링
Pull-Push Hole Filling은 인접 Depth를 이용한 평균
![Page 28: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/28.jpg)
Imperfect Shadow Maps
Result– nVidia 8800GTX
![Page 29: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/29.jpg)
Imperfect Shadow Maps
Result: Bounce– 1024 x 1024, nVidia 8800GTX
14.0fps, 1024 VPL 7.5fps, +256 VPL(bounce) 5.5fps, +256 VPL(bounce) * 2
![Page 30: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/30.jpg)
Imperfect Shadow Maps
Result: Comparison
ISM, 11fps, 256^2, 8k VPL Path Tracing, hours
![Page 31: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/31.jpg)
CLPV
Cascaded Light Propagation Volumes [clpv09] [clpv10a] [clpv10b]
Propagation Volumes– lit surfaces 샘플링, 2차 라이트 소스– 3D Grid 안에 Clustering– 각각의 셀에 전파
RSM 3D Cell에 Clustering 전파
![Page 32: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/32.jpg)
CLPV
Sampling– RSM 기반 샘플링 Depth
NormalsNormals
AlbedoAlbedo
RSMLit Surfel 샘플링
![Page 33: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/33.jpg)
CLPV
Clustering
3D Cell에 Clustering
![Page 34: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/34.jpg)
CLPV
Propagation
VPL
VPL
VPL
RSM Radiance Volume Clustering정규화된 Grid Cell에 SH로 표현
인접 Cell에 전파, 반복
![Page 35: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/35.jpg)
CLPV
Propagation
0 Iterations, only Injection
![Page 36: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/36.jpg)
CLPV
Propagation
4 Iterations after Injection
![Page 37: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/37.jpg)
CLPV
Propagation
6 Iterations
![Page 38: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/38.jpg)
CLPV
Propagation
8 Iterations
![Page 39: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/39.jpg)
CLPV
DepthDepthDepthDepth
NormalsNormalsNormalsNormals
AlbedoAlbedoAlbedoAlbedo
DepthDepth
NormalsNormals
AlbedoAlbedo
![Page 40: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/40.jpg)
CLPV
Cascaded– Multi-Resolution Approach– Cascaded Shadow Maps와 유사– 근접한 곳에 더 디테일한 정보– 렌더링시에 해상도별 동시 참조
3단계 Cascaded LPV
![Page 41: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/41.jpg)
CLPV
Global Illumination Off
![Page 42: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/42.jpg)
CLPV
Global Illumination On / 1 LPV
![Page 43: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/43.jpg)
CLPV
Global Illumination On / 3 LPVs
![Page 44: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/44.jpg)
CLPV
높은 성능– 32^3 Grid, 8 Iterations, 1280 x 720– GTS250 2.4ms (RSM 256 x 256)– Xbox360 2.4ms (RSM 128 x 128)– PS3 3.0ms (RSM 128 x 128)– Frame Skipping 및 Camera 변화에 따른 조절로 1~2ms 수준 최적화
GPU Friendly
안정적인 결과– Scene 복잡도 무관– Flicker-Free
![Page 45: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/45.jpg)
토의 및 결론
Lighting Keywords– Lightmap– Image Based Lighting– Deferred Lighting– Real-Time GI
환경, 품질, 성능에 따라 선택, 혼용
GI로 수렴될 것으로 예상?!
![Page 46: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/46.jpg)
참고 문헌
[cu98] The Cornell Box http://www.graphics.cornell.edu/online/box/
[sc09] Real-Time Global Illumination for Dynamic Scenes, Siggraph Course, Carsten Dachsbacher, Jan Kautz, 2009
[ssdo09] Approximating Dynamic Global Illumination in Screen Space, Tobias Ritschel, Thorsten Grosch, Hans-Peter Seidel, I3D, 2009
[rsm05] Reflective shadow maps, Carsten Dachsbacher and Marc Stamminger, I3D, 2005
[sii07] Splatting Indirect Illumination, Carsten Dachsbacher and Marc Stamminger, 2007
![Page 47: Real-Time Global Illumination Techniques](https://reader031.fdocument.pub/reader031/viewer/2022013121/54b4d8d64a79597d318b4735/html5/thumbnails/47.jpg)
참고 문헌
[ir97] Instant radiosity, Alexander Keller, SIGGRAPH, 1997
[ir08] Instant Radiosity An Approach for Real-Time Global Illumination, Martin Kinkelin and Christian Liensberger, 2008
[ism08] Imperfect shadow maps for efficient computation of indirect illumination, Tobias Ritschel et al., SIGGRAPH Asia, 2008
[clpv09] Light Propagation Volumes in CryEngine 3, Anton Kaplanyan, SIGGRAPH Course, 2009
[clpv10a] Real-time Diffuse Global Illumination in CryENGINE 3, Anton Kaplanyan, SIGGRAPH Course, 2010
[clpv10b] Cascaded Light Propagation Volumes for Real Time Indirect Illumination, Anton Kaplanyan and Carsten Dachsbacher, I3D, 2010