[0806 박민근] 림 라이팅(rim lighting)

  • View
    5.169

  • Download
    7

  • Category

    Business

Preview:

Citation preview

Rim Lighting( 림 라이팅 )

박민근 ( 알콜코더 )데브루키 스터디 2011.08.06

Rim Light-ing 이란 ?

Rim Light = 역광 (Back Light-ing)

오브젝트 뒷면의 조명이 비춰서 , 오브젝트의 외곽이 빛나는 듯이 보이는 현상

(= 엣지 라이팅 )

Rim Light-ing 사용 사례

림 라이트 없음

림 라이트만 렌더링

최종 화면

스타워즈 – 구 공화국(GDC 2011)

Rim Lighting

Rim Lighting

•In film, a light placed behind the character

•Separates the characters from the background

•Highlights shapes and contours

•Game rim light created in the shader

•Our rim light mimics the style of our concepts - not real light behavior

Rim Lighting Evolution

•Began as a way to make skin look nice.

•Art director wanted to try it on everything.

•Original version was too velvety and got too blown out.

•The current implementation has gone through lots of refine-ments.

Rim Light-ing 장점

Rim Lighting

• 캐릭터와 배경을 구별을 명확히 한다

캐릭터가 배경이 묻히는 것을 극복한다

• 물체의 외곽선을 살려준다

• 빛을 받지 않는 부분의 디테일을 높여준다

• 구현이 아주 간단하다

Rim Light-ing 구현

Rim Lighting 구현 코드float3 vCameraPos = normalize( vCameraPos - v.pos );

float fRimLightColor = smoothstep(1.0f - rimWidth, 1.0f,

1 - max(0, dot(v.nor, vCameraPos)));

* 즉 , 캐릭터의 외곽에 가까운지만 판단하면 된다 . ( 외곽선 검출 )

smoothstep()smoothstep(min,max,x)  x 가 [min, max] 사이의 값인 경우에 대해서 [0, 1]

사이에서 부드럽게 변하는 Hermite 보간법을 리턴한다 .

x 가 min 보다 작다면 0 을 리턴하고 , max 보다 크다면 1을 리턴한다 .

UDK 로 구현한Rim Lighting

림 라이팅 (Rim Lighting) / 엣지 라이팅

Q & A