2. Wrapped Diffuse
• 팀 포트리스 2에서 사용
• subsurface scattering, area light source,
더 부드러운 reflectance 를 표현하기 위해
서 Hemisphere(반구)를 감싸는 셰이딩 모
델
Lambert
Wrapped Diffuse
3. Wrapped Diffuse
• HarfLambert 공식과 비슷함
– W=1이면, Half Lambert 공식
• Half Lambert와 유사하게 투과되는 느낌을
표현하는데 많이 사용
– 피부, 나뭇잎, 파티클 라이팅에 주로 사용
기본 Lambert Diffuse 공식
float diffuse = max(0, dot(normal, lightdirection));
기본 HalfLambert Diffuse 공식
float halflambert_term = dot(normal, lightdirection) * 0.5f + 0.5f
Wrapped Diffuse 공식
float diffuse = saturate((dot(normal, lightdirection) + OFFSET) / (1.0+OFFSET ));
4. Wrapped Diffuse
Wrapped SH 자세한 내용
http://blog.selfshadow.com/2011/12/31/righting-wrap-part-1/
http://blog.selfshadow.com/2012/01/07/righting-wrap-part-2/
Wrap Shading
www.iro.umontreal.ca/~derek/files/jgt_wrap.pdf
5. Wrapped Diffuse
• 팀 포트리스 방식
– Wrapped Function은 Half Lambert를 이용해서,
1D Wrapped Diffuse Texture에서 값을 얻어오
는것
– GPU Gems 16. Real-Time Approximation to
Subsurface Scattering
• Wrap Lighting 계산 내용을 미리 Texture로 저장하
여 사용함
7. Specular Fresnel
Mixed Specular
Primary Specularity
Rim Fresnel
Upward Ambient Rim
Final Mix
http://www.sfdm.scad.edu/faculty/mkesson/vsfx419/wip/spring11/eric_kurzmack/toon.html
Rim Specular