Presentation is loading. Please wait.

Presentation is loading. Please wait.

Introduction Hair Geometry Hair Shading Introduction 4,095 individual hairs 123,000 vertices (just for the hair rendering)

Similar presentations


Presentation on theme: "Introduction Hair Geometry Hair Shading Introduction 4,095 individual hairs 123,000 vertices (just for the hair rendering)"— Presentation transcript:

1

2 Introduction Hair Geometry Hair Shading

3 Introduction 4,095 individual hairs 123,000 vertices (just for the hair rendering)

4 Hair Geometry

5 Data Flow

6

7 Tessellation

8 Interpolation Barycentric coefficients: b A + b B + b C = 1 Interpolated hair Y : Y = A x b A + B x b B + C x b C

9 Interpolation

10

11 The Effect of Tessellation and Interpolation

12 Modulate density across scalp

13 Curly Hair

14 Hair Shading a local reflectance model for hair a method for computing self-shadowing between hairs

15 A Real-Time Reflectance Model for Hair The Marschner Reflectance Model S(f i, q i ; f o, q o ) S = S R + S TT + S TRT S p = M p (q i, q o ) x N p (q d, f d ) for P = R, TT, TRT q d = ½(q i – q o ), f d = f i – f o

16 Lookup Textures for the Marschner Hair Reflectance Model

17 Reflectance

18 Pseudocode Summarizing the Shaders // In the Vertex Shader: SinThetaI = dot(light, tangent) ; SinThetaO = dot(eye, tangent) ; LightPerp = light – SinThetaI * tangent ; eyePerp = eye – SinThetaO * tangent ; CosPhiD = dot(eyePerp, lightPerp) * (dot(eyePerp, eyePerp) * dot(lightPerp, lightPerp))^-0.5 // In the Fragment Shader: (MR, MTT, MTRT, cosThetaD) = lookup1(cosThetaI, cosThetaO) (NTT, NR) = lookup2(CosPhiD, cosThetaD) NTRT = lookup3(CosPhiD, cosThetaD) S = MR * NR + MTT * NTT + MTRT * NTRT

19 Real-Time Volumetric Shadows in Hair  Stencil Shadow Volumes  Shadow Maps Opacity Shadow Maps !

20 Opacity Shadow Maps - T(x, y, z) is the fraction of light penetrating to depth z - σ is called the opacity thickness - r(x, y, z) is the extinction coefficient

21 Opacity Shadow Maps where z i < z < z i+1. To compute σ at a discrete set of z values z 0... z n-1 - n = 16 - z 0 being the near plane of the hair in light space - z 15 being the far plane of the hair in light space - z i = z 0 + i dz, dz = (z 15 – z 0 )/16

22 Opacity Shadow Maps

23 Results

24

25 Q & A


Download ppt "Introduction Hair Geometry Hair Shading Introduction 4,095 individual hairs 123,000 vertices (just for the hair rendering)"

Similar presentations


Ads by Google