Next Gen Character Rendering
Next Gen Character Rendering
Next Gen Character Rendering
Character Rendering
Jorge Jimenez Javier von der Pahlen
Technical Director Director of R&D
Activision Blizzard Activision Blizzard
© Activision Blizzard
Disclaimer
• Projectors don’t do justice to the details of our
renderings
• Similarly, slides are best viewed fullscreen, in order to
appreciate all the details and subtleties
• This presentation reflects R&D that ATVI is exploring
• This content is for presentation purposes only and
does not reflect actual design examples nor actual
game assets
Thanks to Dimitar Lazarov and Sébastien Lagarde for sharing the code
Institute of Creative Technology Capture
Two Lobes Rendering (ICT
Reference)
Lobe 2
Lobe 1
Lobe 2
Lobe 1
Thanks to Stephen Hill and Colin Barré-Brisebois for sharing the code/technique
Skin Gloss Map
• What is roughness?
Reflected light Incoming Light
Microfacets
Microfacets
Microfacets
Flat
Variance to Gloss
• Estimate normal variance, and use it as
glossiness
• More details on the reference below
Noisy
• Gloss:
– Only low frequency details
– High frequency details come from variance to
gloss (both from normal and detail normal maps)
Render Photograph
From [Graham2013] Measurement-Based Synthesis of Facial Microgeometry
Comparing with Reality
Render Photograph
From [Graham2013] Measurement-Based Synthesis of Facial Microgeometry
Cavity Occlusion
Off © Activision Blizzard
On © Activision Blizzard
Off © Activision Blizzard
On © Activision Blizzard
On © Activision Blizzard
What’s Going On?
• You cannot see the pore’s holes from
the side!
• Remove the cavity occlusion in that
case
• Theoretically, cavity is an occlusion
value:
– cavity * Specular(gloss) *
Fresnel(reflectance)
• However it can be cheaply removed at
grazing angles if used like this:
– Specular(gloss) * Fresnel(cavity *
reflectance)
• In practical terms, place cavity on the
reflectance slot
cavity * Specular(gloss, reflectance) © Activision Blizzard
Specular(gloss, cavity * reflectance) © Activision Blizzard
(Faking) Global Illumination
1. Skin Rendering
1. Skin Reflections
2. Human Pores
3. Global Illumination
4. Subsurface Scattering
2. Eyes Rendering
3. Post FX
(Faking) Global Illumination
• Occlusion is crucial if (physically based)
HDR light probes are used for lighting
• Both for the eyes and the skin
Full © Activision Blizzard
No Occlusion © Activision Blizzard
+HBAO © Activision Blizzard
+Baked © Activision Blizzard
+Power Specular © Activision Blizzard
Thanks to Angelo Pesce for the ideas and support!
+Color-Bleed AO
Combining SSAO with Baked
• We use the minimum of both:
AO
– finalAO = min(BakedAO, SSAO)
• Regular AO:
ao * color
Color-Bleed AO
• We developed a multi-pass ambient occlusion
renderer that takes the color of blockers into account
• Rays are weighted:
– When a ray hits the sky:
• On all passes: float3(1.0, 1.0, 1.0)
– When a ray hits the geometry:
• On first pass: float3(0.0, 0.0, 0.0)
• On following passes: diffuse * previousAO
• Calculations and maps in linear space
– Critical for AO
Regular AO Color-Bleed AO
Color-Bleed AO
• For character heads, the difference is subtle enough to
be expressed with a gamma correction:
colorBleedAO = pow(regularAO,1.0 - strength)
• For Lauren:
strength = float3(0.4,0.15,0.13)
BRDF BSSRDF
4D 8D 1D [Henrik2001]
BRDF BSSRDF
Texture Space
Screen Space
Problems
• Still not practical for games:
– Blurring in texture space is costly
– Six Gaussians are still expensive
Separable Approximation
• We shifted it to screen-space:
– [Jimenez2009] Screen-Space Perceptual Rendering of Human
Skin
if (initStencil)
if (colorM.a == 0.0) discard;
[unroll]
for (int i = 1; i < N_SAMPLES; i++) {
float2 offset = texcoord + kernel[i].a * finalStep;
float4 color = colorTex.Sample(LinearSampler, offset);
#if FOLLOW_SURFACE == 1
float depth = depthTex.Sample(LinearSampler, offset);
float s = saturate(0.5 * width * abs(depthM - depth));
color.rgb = lerp(color.rgb, colorM.rgb, s);
#endif
return colorBlurred;
...
• Visually tweaking these parameters, we were able to match the three-layer multipole SSS
profile ([Eon2007] Advanced Techniques for Realistic Real-Time Skin Rendering)
Z XY
Low Mid Hi
No Wetness Geometry © Activision Blizzard
Wetness Geometry © Activision Blizzard
No Wetness Geometry Wetness Geometry
No Blur © Activision Blizzard
Blur © Activision Blizzard
The Sparkle of the Eye
• We have covered just two aspects that give clues about eye
wetness:
– Tear fluid distortions
– Tear fluid accumulation on eyelids
• But there’s more to it:
– There is evidence that reflection intensity changes depending on
wetness:
• [Goto2011] The Sparkle of the Eye: The Impact of Ocular Surface Wetness on Corneal
Light Reflection
– However the reason is not yet known
• Gloss change due to different tear composition?
• Reflectance change due to a multilayer thin film?
• Thintofilm
Thanks interference?
Sébastien Lagarde for the countless conversations about the topic
Reflections Occlusion (Motivation)
Off © Activision Blizzard
On © Activision Blizzard
Baked Reflection Occlusion
Reflection Occlusion Map Shader
#if EYE_REFLECTION_OCCLUSION_PARALLAX == 1
viewW.y = -viewW.y;
texcoord -= 0.14 * viewW.xy;
texcoord -= 0.01 * normalT;
#endif
return aoTex.Sample(AnisotropicSampler, coord).g;
On
Screen-Space Reflections (Motivation)
Screen-Space Reflections (Motivation)
Screen-Space Reflections
• In harsh lighting configurations, local
reflections are important
• We explored the possibility of using
screen-space reflections for the eyes (see
[Kasyan2011] Secrets of CryENGINE 3
Graphics Technology)
←Inclination angle→
Schematic View
© Activision Blizzard
Shadow Mapping Tips
• Light refraction generates lit surfaces at
angles where shadow mapping is completely
blocking light
• No trivial way to refract shadow rays using
shadow mapping
Thanks to Steve McAuley for extending the wrapped diffuse normalization to the power case
Off © Activision Blizzard
On © Activision Blizzard
Redness Shading (Motivation)
Redness Shading
• Independent control
for veins and sclera is
desirable
• Coincidentally, the
blue channel of the
sclera looks like a
veins mask
© Activision Blizzard
© Activision Blizzard
© Activision Blizzard
© Activision Blizzard
© Activision Blizzard
© Activision Blizzard
Post FX
1. Skin Rendering
1. Skin Reflections
2. Human Pores
3. Global Illumination
4. Subsurface Scattering
2. Eyes Rendering
3. Post FX
Full HD
Oleg Alexander, Graham Fyffe, Jay Busch, Ryosuke Ichikari, Abhijeet Ghosh, Andrew
Jones, Paul Graham, Svetlana Akim, Xueming Yu, Koki Nagano, Borom
Tunwattanapong, Valerie Dauphin, Ari Shapiro, Kathleen Haase, Paul Debevec
Specular Albedo
Diffuse albedo
• For each vertex, we want to find the 4 bone weights to minimize the error.
Diffuse albedo
corresponding to
each scan
© Activision Blizzard
Thanks for your attention!
Special thanks to (in alphabetical order):
Angelo Pesce, Carl Schnurr, Chris Codding, Chris Ellis,
Colin Barré-Brisebois, David Bullat, Dimitar Lazarov, Lee
Perry, Jennifer Velazquez, María López, Sébastien
Lagarde, Stephen Hill, Steve McAuley, Xian-Chun Wu.