SlideShare a Scribd company logo
Deferred Shading

  Shawn Hargreaves
Overview
• Don’t bother with any lighting while drawing scene
  geometry
• Render to a “fat” framebuffer format, using multiple
  rendertargets to store data such as the position and
  normal of each pixel
• Apply lighting as a 2D postprocess, using these
  buffers as input
Comparison: Single Pass Lighting
For each object:
  Render mesh, applying all lights in one shader

• Good for scenes with small numbers of lights (eg.
  outdoor sunlight)
• Difficult to organize if there are many lights
• Easy to overflow shader length limitations
Comparison: Multipass Lighting
For each light:
  For each object affected by the light:
      framebuffer += object * light

• Worst case complexity is num_objects * num_lights
• Sorting by light or by object are mutually exclusive:
  hard to maintain good batching
• Ideally the scene should be split exactly along light
  boundaries, but getting this right for dynamic lights
  can be a lot of CPU work
Deferred Shading
For each object:
  Render to multiple targets

For each light:
  Apply light as a 2D postprocess

• Worst case complexity is num_objects + num_lights
• Perfect batching
• Many small lights are just as cheap as a few big ones
Multiple Render Targets
• Required outputs from the geometry rendering are:
   – Position
   – Normal
   – Material parameters (diffuse color, emissive, specular
     amount, specular power, etc)

• This is not good if your lighting needs many input
  values! (spherical harmonics would be difficult)
Fat Framebuffers
• The obvious rendertarget layout goes something like:
   –   Position              A32B32G32R32F
   –   Normal                A16B16G16R16F
   –   Diffuse color         A8R8G8B8
   –   Material parameters   A8R8G8B8

• This adds up to 256 bits per pixel. At 1024x768, that
  is 24 meg, even without antialiasing!
• Also, current hardware doesn’t support mixing
  different bit depths for multiple rendertargets
Framebuffer Size Optimizations
• Store normals in A2R10G10B10 format
• Material attributes could be palettized, then looked up
  in shader constants or a texture
• No need to store position as a vector3:
   – Each 2D screen pixel corresponds to a ray from the eyepoint
     into the 3D world (think raytracing)
   – You inherently know the 2D position of each screen pixel,
     and you know the camera settings
   – So if you write out the distance along this ray, you can
     reconstruct the original worldspace position
My Framebuffer Choices
• 128 bits per pixel = 12 meg @ 1024x768:
   –   Depth                       R32F
   –   Normal + scattering         A2R10G10B10
   –   Diffuse color + emissive    A8R8G8B8
   –   Other material parameters   A8R8G8B8

• My material parameters are specular intensity,
  specular power, occlusion factor, and shadow
  amount. I store a 2-bit subsurface scattering control
  in the alpha channel of the normal buffer
Depth
Buffer

Specular
Intensity /
Power
Normal
Buffer
Diffuse
Color
Buffer
Deferred
Lighting
Results
How Wasteful…
• One of my 32 bit buffers holds depth values
• But the hardware is already doing this for me!
• It would be nice if there was an efficient way to get
  access to the existing contents of the Z buffer
• Pretty please? ☺
Global Lights
• Things like sunlight and fog affect the entire scene
• Draw them as a fullscreen quad
• Position, normal, color, and material settings are read
  from texture inputs
• Lighting calculation is evaluated in the pixel shader
• Output goes to an intermediate lighting buffer
Local Lights
• These only affect part of the scene
• We only want to render to the affected pixels
• This requires projecting the light volume into
  screenspace. The GPU is very good at that sort of
  thing…
• At author time, build a simple mesh that bounds the
  area affected by the light. At runtime, draw this in 3D
  space, running your lighting shader over each pixel
  that it covers
Convex Light Hulls
• The light bounding
  mesh will have two
  sides, but it is important
  that each pixel only gets
  lit once
• As long as the mesh is
  convex, backface
  culling can take care of
  this
Convex Light Hulls
• The light bounding
  mesh will have two
  sides, but it is important
  that each pixel only gets
  lit once
• As long as the mesh is
  convex, backface
  culling can take care of
  this
Convex Light Hulls #2
• If the camera is inside
  the light volume, draw
  backfaces
Convex Light Hulls #3
• If the light volume
  intersects the far clip
  plane, draw frontfaces
• If the light volume
  intersects both near and
  far clip planes, your
  light is too big!
Volume Optimization
• We only want to shade
  the area where the light
  volume intersects scene
  geometry
• There is no need to
  shade where the
  volume is suspended in
  midair
• Or where it is buried
  beneath the ground
Stencil Light Volumes
• This is exactly the same problem as finding the
  intersection between scene geometry and an
  extruded shadow volume
• The standard stencil buffer solution applies
• But using stencil requires changing renderstate for
  each light, which prevents batching up multiple lights
  into a single draw call
• Using stencil may or may not be a performance win,
  depending on context
Light Volume Z Tests
• A simple Z test can get
  things half-right, without
  the overhead of using
  stencil
• When drawing light
  volume backfaces, use
  D3DCMP_GREATER to
  reject “floating in the air”
  portions of the light
Light Volume Z Tests #2
• If drawing frontfaces, use
  D3DCMP_LESS to reject
  “buried underground”
  light regions
• Which is faster depends
  on the ratio of
  aboveground vs.
  underground pixels: use
  a heuristic to make a
  guess
Alpha Blending
• This is a big problem!
• You could simply not do any lighting on alpha
  blended things, and draw them after the deferred
  shading is complete. The emissive and occlusion
  material controls are useful for crossfading between
  lit and non-lit geometry
• The return of stippling?
• Depth peeling is the ultimate solution, but is
  prohibitively expensive at least for the time being
High Dynamic Range
• You can do deferred shading without HDR, but that
  wouldn’t be so much fun
• Render your scene to multiple 32 bit buffers, then use
  a 64 bit accumulation buffer during the lighting phase
• Unfortunately, current hardware doesn’t support
  additive blending into 64 bit rendertargets
• Workaround: use a pair of HDR buffers, and simulate
  alpha blending in the pixel shader
DIY Alpha Blending
• Initialize buffers A and B to the same contents
• Set buffer A as a shader input, while rendering to B,
  and roll your own blend at the end of the shader
• This only works as long as your geometry doesn’t
  overlap in screenspace
• When things do overlap, you have to copy all
  modified pixels from B back into A, to make sure the
  input and output buffers stay in sync
• This is slow, but not totally impractical as long as you
  sort your lights to minimize screenspace overlaps
HDR
Results
Volumetric Depth Tests
• Neat side effect of having scene depth available as a
  shader input
• Gradually fade out alpha as a polygon approaches
  the Z fail threshold
• No more hard edges where alpha blended particles
  intersect world geometry!
Deferred Shading Advantages
•   Excellent batching
•   Render each triangle exactly once
•   Shade each visible pixel exactly once
•   Easy to add new types of lighting shader
•   Other kinds of postprocessing (blur, heathaze) are
    just special lights, and fit neatly into the existing
    framework
The Dark Side
• Alpha blending is a nightmare!
• Framebuffer bandwidth can easily get out of hand
• Can’t take advantage of hardware multisampling
• Forces a single lighting model across the entire
  scene (everything has to be 100% per-pixel)
• Not a good approach for older hardware
• But will be increasingly attractive in the future…
The End
• Any questions?

More Related Content

What's hot

Deferred Rendering in Killzone 2
Deferred Rendering in Killzone 2Deferred Rendering in Killzone 2
Deferred Rendering in Killzone 2ozlael ozlael
 
Calibrating Lighting and Materials in Far Cry 3
Calibrating Lighting and Materials in Far Cry 3Calibrating Lighting and Materials in Far Cry 3
Calibrating Lighting and Materials in Far Cry 3
stevemcauley
 
Around the World in 80 Shaders
Around the World in 80 ShadersAround the World in 80 Shaders
Around the World in 80 Shaders
stevemcauley
 
The Rendering Technology of Killzone 2
The Rendering Technology of Killzone 2The Rendering Technology of Killzone 2
The Rendering Technology of Killzone 2
Guerrilla
 
Crysis Next-Gen Effects (GDC 2008)
Crysis Next-Gen Effects (GDC 2008)Crysis Next-Gen Effects (GDC 2008)
Crysis Next-Gen Effects (GDC 2008)Tiago Sousa
 
Secrets of CryENGINE 3 Graphics Technology
Secrets of CryENGINE 3 Graphics TechnologySecrets of CryENGINE 3 Graphics Technology
Secrets of CryENGINE 3 Graphics Technology
Tiago Sousa
 
Forward+ (EUROGRAPHICS 2012)
Forward+ (EUROGRAPHICS 2012)Forward+ (EUROGRAPHICS 2012)
Forward+ (EUROGRAPHICS 2012)Takahiro Harada
 
Star Ocean 4 - Flexible Shader Managment and Post-processing
Star Ocean 4 - Flexible Shader Managment and Post-processingStar Ocean 4 - Flexible Shader Managment and Post-processing
Star Ocean 4 - Flexible Shader Managment and Post-processing
umsl snfrzb
 
Destruction Masking in Frostbite 2 using Volume Distance Fields
Destruction Masking in Frostbite 2 using Volume Distance FieldsDestruction Masking in Frostbite 2 using Volume Distance Fields
Destruction Masking in Frostbite 2 using Volume Distance Fields
Electronic Arts / DICE
 
Shiny PC Graphics in Battlefield 3
Shiny PC Graphics in Battlefield 3Shiny PC Graphics in Battlefield 3
Shiny PC Graphics in Battlefield 3
Electronic Arts / DICE
 
Paris Master Class 2011 - 01 Deferred Lighting, MSAA
Paris Master Class 2011 - 01 Deferred Lighting, MSAAParis Master Class 2011 - 01 Deferred Lighting, MSAA
Paris Master Class 2011 - 01 Deferred Lighting, MSAA
Wolfgang Engel
 
Rendering AAA-Quality Characters of Project A1
Rendering AAA-Quality Characters of Project A1Rendering AAA-Quality Characters of Project A1
Rendering AAA-Quality Characters of Project A1
Ki Hyunwoo
 
Photogrammetry and Star Wars Battlefront
Photogrammetry and Star Wars BattlefrontPhotogrammetry and Star Wars Battlefront
Photogrammetry and Star Wars Battlefront
Electronic Arts / DICE
 
Epic_GDC2011_Samaritan
Epic_GDC2011_SamaritanEpic_GDC2011_Samaritan
Epic_GDC2011_SamaritanMinGeun Park
 
GDC 2014 - Deformable Snow Rendering in Batman: Arkham Origins
GDC 2014 - Deformable Snow Rendering in Batman: Arkham OriginsGDC 2014 - Deformable Snow Rendering in Batman: Arkham Origins
GDC 2014 - Deformable Snow Rendering in Batman: Arkham Origins
Colin Barré-Brisebois
 
Rendering Technologies from Crysis 3 (GDC 2013)
Rendering Technologies from Crysis 3 (GDC 2013)Rendering Technologies from Crysis 3 (GDC 2013)
Rendering Technologies from Crysis 3 (GDC 2013)
Tiago Sousa
 
CEDEC 2018 - Towards Effortless Photorealism Through Real-Time Raytracing
CEDEC 2018 - Towards Effortless Photorealism Through Real-Time RaytracingCEDEC 2018 - Towards Effortless Photorealism Through Real-Time Raytracing
CEDEC 2018 - Towards Effortless Photorealism Through Real-Time Raytracing
Electronic Arts / DICE
 
Terrain Rendering in Frostbite using Procedural Shader Splatting (Siggraph 2007)
Terrain Rendering in Frostbite using Procedural Shader Splatting (Siggraph 2007)Terrain Rendering in Frostbite using Procedural Shader Splatting (Siggraph 2007)
Terrain Rendering in Frostbite using Procedural Shader Splatting (Siggraph 2007)Johan Andersson
 
GTC 2014 - DirectX 11 Rendering and NVIDIA GameWorks in Batman: Arkham Origins
GTC 2014 - DirectX 11 Rendering and NVIDIA GameWorks in Batman: Arkham OriginsGTC 2014 - DirectX 11 Rendering and NVIDIA GameWorks in Batman: Arkham Origins
GTC 2014 - DirectX 11 Rendering and NVIDIA GameWorks in Batman: Arkham Origins
Colin Barré-Brisebois
 
The rendering technology of 'lords of the fallen' philip hammer
The rendering technology of 'lords of the fallen'   philip hammerThe rendering technology of 'lords of the fallen'   philip hammer
The rendering technology of 'lords of the fallen' philip hammer
Mary Chan
 

What's hot (20)

Deferred Rendering in Killzone 2
Deferred Rendering in Killzone 2Deferred Rendering in Killzone 2
Deferred Rendering in Killzone 2
 
Calibrating Lighting and Materials in Far Cry 3
Calibrating Lighting and Materials in Far Cry 3Calibrating Lighting and Materials in Far Cry 3
Calibrating Lighting and Materials in Far Cry 3
 
Around the World in 80 Shaders
Around the World in 80 ShadersAround the World in 80 Shaders
Around the World in 80 Shaders
 
The Rendering Technology of Killzone 2
The Rendering Technology of Killzone 2The Rendering Technology of Killzone 2
The Rendering Technology of Killzone 2
 
Crysis Next-Gen Effects (GDC 2008)
Crysis Next-Gen Effects (GDC 2008)Crysis Next-Gen Effects (GDC 2008)
Crysis Next-Gen Effects (GDC 2008)
 
Secrets of CryENGINE 3 Graphics Technology
Secrets of CryENGINE 3 Graphics TechnologySecrets of CryENGINE 3 Graphics Technology
Secrets of CryENGINE 3 Graphics Technology
 
Forward+ (EUROGRAPHICS 2012)
Forward+ (EUROGRAPHICS 2012)Forward+ (EUROGRAPHICS 2012)
Forward+ (EUROGRAPHICS 2012)
 
Star Ocean 4 - Flexible Shader Managment and Post-processing
Star Ocean 4 - Flexible Shader Managment and Post-processingStar Ocean 4 - Flexible Shader Managment and Post-processing
Star Ocean 4 - Flexible Shader Managment and Post-processing
 
Destruction Masking in Frostbite 2 using Volume Distance Fields
Destruction Masking in Frostbite 2 using Volume Distance FieldsDestruction Masking in Frostbite 2 using Volume Distance Fields
Destruction Masking in Frostbite 2 using Volume Distance Fields
 
Shiny PC Graphics in Battlefield 3
Shiny PC Graphics in Battlefield 3Shiny PC Graphics in Battlefield 3
Shiny PC Graphics in Battlefield 3
 
Paris Master Class 2011 - 01 Deferred Lighting, MSAA
Paris Master Class 2011 - 01 Deferred Lighting, MSAAParis Master Class 2011 - 01 Deferred Lighting, MSAA
Paris Master Class 2011 - 01 Deferred Lighting, MSAA
 
Rendering AAA-Quality Characters of Project A1
Rendering AAA-Quality Characters of Project A1Rendering AAA-Quality Characters of Project A1
Rendering AAA-Quality Characters of Project A1
 
Photogrammetry and Star Wars Battlefront
Photogrammetry and Star Wars BattlefrontPhotogrammetry and Star Wars Battlefront
Photogrammetry and Star Wars Battlefront
 
Epic_GDC2011_Samaritan
Epic_GDC2011_SamaritanEpic_GDC2011_Samaritan
Epic_GDC2011_Samaritan
 
GDC 2014 - Deformable Snow Rendering in Batman: Arkham Origins
GDC 2014 - Deformable Snow Rendering in Batman: Arkham OriginsGDC 2014 - Deformable Snow Rendering in Batman: Arkham Origins
GDC 2014 - Deformable Snow Rendering in Batman: Arkham Origins
 
Rendering Technologies from Crysis 3 (GDC 2013)
Rendering Technologies from Crysis 3 (GDC 2013)Rendering Technologies from Crysis 3 (GDC 2013)
Rendering Technologies from Crysis 3 (GDC 2013)
 
CEDEC 2018 - Towards Effortless Photorealism Through Real-Time Raytracing
CEDEC 2018 - Towards Effortless Photorealism Through Real-Time RaytracingCEDEC 2018 - Towards Effortless Photorealism Through Real-Time Raytracing
CEDEC 2018 - Towards Effortless Photorealism Through Real-Time Raytracing
 
Terrain Rendering in Frostbite using Procedural Shader Splatting (Siggraph 2007)
Terrain Rendering in Frostbite using Procedural Shader Splatting (Siggraph 2007)Terrain Rendering in Frostbite using Procedural Shader Splatting (Siggraph 2007)
Terrain Rendering in Frostbite using Procedural Shader Splatting (Siggraph 2007)
 
GTC 2014 - DirectX 11 Rendering and NVIDIA GameWorks in Batman: Arkham Origins
GTC 2014 - DirectX 11 Rendering and NVIDIA GameWorks in Batman: Arkham OriginsGTC 2014 - DirectX 11 Rendering and NVIDIA GameWorks in Batman: Arkham Origins
GTC 2014 - DirectX 11 Rendering and NVIDIA GameWorks in Batman: Arkham Origins
 
The rendering technology of 'lords of the fallen' philip hammer
The rendering technology of 'lords of the fallen'   philip hammerThe rendering technology of 'lords of the fallen'   philip hammer
The rendering technology of 'lords of the fallen' philip hammer
 

Viewers also liked

Deferred Rendering in Killzone 2
Deferred Rendering in Killzone 2Deferred Rendering in Killzone 2
Deferred Rendering in Killzone 2
Guerrilla
 
Lighting of Killzone: Shadow Fall
Lighting of Killzone: Shadow FallLighting of Killzone: Shadow Fall
Lighting of Killzone: Shadow Fall
Guerrilla
 
DirectX 11 Rendering in Battlefield 3
DirectX 11 Rendering in Battlefield 3DirectX 11 Rendering in Battlefield 3
DirectX 11 Rendering in Battlefield 3
Electronic Arts / DICE
 
Keyword Research for Pay-Per-Click Marketing
Keyword Research for Pay-Per-Click MarketingKeyword Research for Pay-Per-Click Marketing
Keyword Research for Pay-Per-Click MarketingMatt DeYoung
 
كيفية البحث عن اصدقائك في جيران أو دعوتهم الى جيران في حال لم يشتركوا بعد؟
كيفية البحث عن اصدقائك في جيران أو دعوتهم الى جيران في حال لم يشتركوا بعد؟كيفية البحث عن اصدقائك في جيران أو دعوتهم الى جيران في حال لم يشتركوا بعد؟
كيفية البحث عن اصدقائك في جيران أو دعوتهم الى جيران في حال لم يشتركوا بعد؟
guest9e2421
 
Mumbrella - Programmatic For Marketers
Mumbrella - Programmatic For MarketersMumbrella - Programmatic For Marketers
Mumbrella - Programmatic For Marketers
Louder
 
James Van Fleteren
James Van FleterenJames Van Fleteren
James Van Fleteren
James_Van_Fleteren
 
Ordering Via Twitter
Ordering Via TwitterOrdering Via Twitter
Ordering Via Twitter
guestd41b37
 
Citizen Presentation
Citizen PresentationCitizen Presentation
Citizen Presentationcitizensondra
 
Cctv cameras
Cctv camerasCctv cameras
Cctv cameras
sparshamit
 
Social engagement intro zeethos
Social engagement intro zeethosSocial engagement intro zeethos
Social engagement intro zeethoschrisjlewis
 
Guide to Planning Your Next Web Project
Guide to Planning Your Next Web ProjectGuide to Planning Your Next Web Project
Guide to Planning Your Next Web Project
CommonPlaces e-Solutions
 

Viewers also liked (20)

Deferred Rendering in Killzone 2
Deferred Rendering in Killzone 2Deferred Rendering in Killzone 2
Deferred Rendering in Killzone 2
 
Lighting of Killzone: Shadow Fall
Lighting of Killzone: Shadow FallLighting of Killzone: Shadow Fall
Lighting of Killzone: Shadow Fall
 
DirectX 11 Rendering in Battlefield 3
DirectX 11 Rendering in Battlefield 3DirectX 11 Rendering in Battlefield 3
DirectX 11 Rendering in Battlefield 3
 
Keyword Research for Pay-Per-Click Marketing
Keyword Research for Pay-Per-Click MarketingKeyword Research for Pay-Per-Click Marketing
Keyword Research for Pay-Per-Click Marketing
 
Safety
SafetySafety
Safety
 
Mitchell
MitchellMitchell
Mitchell
 
Nerva Nevada
Nerva NevadaNerva Nevada
Nerva Nevada
 
Prologue np1
Prologue np1Prologue np1
Prologue np1
 
before upload
before uploadbefore upload
before upload
 
كيفية البحث عن اصدقائك في جيران أو دعوتهم الى جيران في حال لم يشتركوا بعد؟
كيفية البحث عن اصدقائك في جيران أو دعوتهم الى جيران في حال لم يشتركوا بعد؟كيفية البحث عن اصدقائك في جيران أو دعوتهم الى جيران في حال لم يشتركوا بعد؟
كيفية البحث عن اصدقائك في جيران أو دعوتهم الى جيران في حال لم يشتركوا بعد؟
 
Mumbrella - Programmatic For Marketers
Mumbrella - Programmatic For MarketersMumbrella - Programmatic For Marketers
Mumbrella - Programmatic For Marketers
 
Mercalli Lab
Mercalli LabMercalli Lab
Mercalli Lab
 
ttt
tttttt
ttt
 
James Van Fleteren
James Van FleterenJames Van Fleteren
James Van Fleteren
 
Ordering Via Twitter
Ordering Via TwitterOrdering Via Twitter
Ordering Via Twitter
 
Citizen Presentation
Citizen PresentationCitizen Presentation
Citizen Presentation
 
I pv6
I pv6I pv6
I pv6
 
Cctv cameras
Cctv camerasCctv cameras
Cctv cameras
 
Social engagement intro zeethos
Social engagement intro zeethosSocial engagement intro zeethos
Social engagement intro zeethos
 
Guide to Planning Your Next Web Project
Guide to Planning Your Next Web ProjectGuide to Planning Your Next Web Project
Guide to Planning Your Next Web Project
 

Similar to Deferred shading

Real-time lightmap baking
Real-time lightmap bakingReal-time lightmap baking
Real-time lightmap baking
Rosario Leonardi
 
WT in IP.ppt
WT in IP.pptWT in IP.ppt
WT in IP.ppt
viveksingh19210115
 
[UniteKorea2013] The Unity Rendering Pipeline
[UniteKorea2013] The Unity Rendering Pipeline[UniteKorea2013] The Unity Rendering Pipeline
[UniteKorea2013] The Unity Rendering Pipeline
William Hugo Yang
 
「原神」におけるコンソールプラットフォーム開発
「原神」におけるコンソールプラットフォーム開発「原神」におけるコンソールプラットフォーム開発
「原神」におけるコンソールプラットフォーム開発
Unity Technologies Japan K.K.
 
Develop2012 deferred sanchez_stachowiak
Develop2012 deferred sanchez_stachowiakDevelop2012 deferred sanchez_stachowiak
Develop2012 deferred sanchez_stachowiak
Matt Filer
 
The Technology Behind the DirectX 11 Unreal Engine"Samaritan" Demo
The Technology Behind the DirectX 11 Unreal Engine"Samaritan" DemoThe Technology Behind the DirectX 11 Unreal Engine"Samaritan" Demo
The Technology Behind the DirectX 11 Unreal Engine"Samaritan" Demodrandom
 
Unite Berlin 2018 - Book of the Dead Optimizing Performance for High End Cons...
Unite Berlin 2018 - Book of the Dead Optimizing Performance for High End Cons...Unite Berlin 2018 - Book of the Dead Optimizing Performance for High End Cons...
Unite Berlin 2018 - Book of the Dead Optimizing Performance for High End Cons...
Unity Technologies
 
A Practical and Robust Bump-mapping Technique for Today’s GPUs (slides)
A Practical and Robust Bump-mapping Technique for Today’s GPUs (slides)A Practical and Robust Bump-mapping Technique for Today’s GPUs (slides)
A Practical and Robust Bump-mapping Technique for Today’s GPUs (slides)
Mark Kilgard
 
Paris Master Class 2011 - 07 Dynamic Global Illumination
Paris Master Class 2011 - 07 Dynamic Global IlluminationParis Master Class 2011 - 07 Dynamic Global Illumination
Paris Master Class 2011 - 07 Dynamic Global Illumination
Wolfgang Engel
 
[TGDF 2020] Mobile Graphics Best Practices for Artist
[TGDF 2020] Mobile Graphics Best Practices for Artist[TGDF 2020] Mobile Graphics Best Practices for Artist
[TGDF 2020] Mobile Graphics Best Practices for Artist
Owen Wu
 
Taking Killzone Shadow Fall Image Quality Into The Next Generation
Taking Killzone Shadow Fall Image Quality Into The Next GenerationTaking Killzone Shadow Fall Image Quality Into The Next Generation
Taking Killzone Shadow Fall Image Quality Into The Next Generation
Guerrilla
 
【Unite 2018 Tokyo】プログレッシブライトマッパーの真価を発揮する秘訣
【Unite 2018 Tokyo】プログレッシブライトマッパーの真価を発揮する秘訣【Unite 2018 Tokyo】プログレッシブライトマッパーの真価を発揮する秘訣
【Unite 2018 Tokyo】プログレッシブライトマッパーの真価を発揮する秘訣
Unity Technologies Japan K.K.
 
From Experimentation to Production: The Future of WebGL
From Experimentation to Production: The Future of WebGLFrom Experimentation to Production: The Future of WebGL
From Experimentation to Production: The Future of WebGL
FITC
 
Progressive Lightmapper: An Introduction to Lightmapping in Unity
Progressive Lightmapper: An Introduction to Lightmapping in UnityProgressive Lightmapper: An Introduction to Lightmapping in Unity
Progressive Lightmapper: An Introduction to Lightmapping in Unity
Unity Technologies
 
Technologies Used In Graphics Rendering
Technologies Used In Graphics RenderingTechnologies Used In Graphics Rendering
Technologies Used In Graphics Rendering
Bhupinder Singh
 
Felwyrld Tech
Felwyrld TechFelwyrld Tech
Felwyrld Tech
Alex Nankervis
 
Cahall Final Intern Presentation
Cahall Final Intern PresentationCahall Final Intern Presentation
Cahall Final Intern PresentationDaniel Cahall
 
A modern Post-Processing Pipeline
A modern Post-Processing PipelineA modern Post-Processing Pipeline
A modern Post-Processing Pipeline
Wolfgang Engel
 
A new Post-Processing Pipeline
A new Post-Processing PipelineA new Post-Processing Pipeline
A new Post-Processing Pipeline
Wolfgang Engel
 
Paris Master Class 2011 - 05 Post-Processing Pipeline
Paris Master Class 2011 - 05 Post-Processing PipelineParis Master Class 2011 - 05 Post-Processing Pipeline
Paris Master Class 2011 - 05 Post-Processing Pipeline
Wolfgang Engel
 

Similar to Deferred shading (20)

Real-time lightmap baking
Real-time lightmap bakingReal-time lightmap baking
Real-time lightmap baking
 
WT in IP.ppt
WT in IP.pptWT in IP.ppt
WT in IP.ppt
 
[UniteKorea2013] The Unity Rendering Pipeline
[UniteKorea2013] The Unity Rendering Pipeline[UniteKorea2013] The Unity Rendering Pipeline
[UniteKorea2013] The Unity Rendering Pipeline
 
「原神」におけるコンソールプラットフォーム開発
「原神」におけるコンソールプラットフォーム開発「原神」におけるコンソールプラットフォーム開発
「原神」におけるコンソールプラットフォーム開発
 
Develop2012 deferred sanchez_stachowiak
Develop2012 deferred sanchez_stachowiakDevelop2012 deferred sanchez_stachowiak
Develop2012 deferred sanchez_stachowiak
 
The Technology Behind the DirectX 11 Unreal Engine"Samaritan" Demo
The Technology Behind the DirectX 11 Unreal Engine"Samaritan" DemoThe Technology Behind the DirectX 11 Unreal Engine"Samaritan" Demo
The Technology Behind the DirectX 11 Unreal Engine"Samaritan" Demo
 
Unite Berlin 2018 - Book of the Dead Optimizing Performance for High End Cons...
Unite Berlin 2018 - Book of the Dead Optimizing Performance for High End Cons...Unite Berlin 2018 - Book of the Dead Optimizing Performance for High End Cons...
Unite Berlin 2018 - Book of the Dead Optimizing Performance for High End Cons...
 
A Practical and Robust Bump-mapping Technique for Today’s GPUs (slides)
A Practical and Robust Bump-mapping Technique for Today’s GPUs (slides)A Practical and Robust Bump-mapping Technique for Today’s GPUs (slides)
A Practical and Robust Bump-mapping Technique for Today’s GPUs (slides)
 
Paris Master Class 2011 - 07 Dynamic Global Illumination
Paris Master Class 2011 - 07 Dynamic Global IlluminationParis Master Class 2011 - 07 Dynamic Global Illumination
Paris Master Class 2011 - 07 Dynamic Global Illumination
 
[TGDF 2020] Mobile Graphics Best Practices for Artist
[TGDF 2020] Mobile Graphics Best Practices for Artist[TGDF 2020] Mobile Graphics Best Practices for Artist
[TGDF 2020] Mobile Graphics Best Practices for Artist
 
Taking Killzone Shadow Fall Image Quality Into The Next Generation
Taking Killzone Shadow Fall Image Quality Into The Next GenerationTaking Killzone Shadow Fall Image Quality Into The Next Generation
Taking Killzone Shadow Fall Image Quality Into The Next Generation
 
【Unite 2018 Tokyo】プログレッシブライトマッパーの真価を発揮する秘訣
【Unite 2018 Tokyo】プログレッシブライトマッパーの真価を発揮する秘訣【Unite 2018 Tokyo】プログレッシブライトマッパーの真価を発揮する秘訣
【Unite 2018 Tokyo】プログレッシブライトマッパーの真価を発揮する秘訣
 
From Experimentation to Production: The Future of WebGL
From Experimentation to Production: The Future of WebGLFrom Experimentation to Production: The Future of WebGL
From Experimentation to Production: The Future of WebGL
 
Progressive Lightmapper: An Introduction to Lightmapping in Unity
Progressive Lightmapper: An Introduction to Lightmapping in UnityProgressive Lightmapper: An Introduction to Lightmapping in Unity
Progressive Lightmapper: An Introduction to Lightmapping in Unity
 
Technologies Used In Graphics Rendering
Technologies Used In Graphics RenderingTechnologies Used In Graphics Rendering
Technologies Used In Graphics Rendering
 
Felwyrld Tech
Felwyrld TechFelwyrld Tech
Felwyrld Tech
 
Cahall Final Intern Presentation
Cahall Final Intern PresentationCahall Final Intern Presentation
Cahall Final Intern Presentation
 
A modern Post-Processing Pipeline
A modern Post-Processing PipelineA modern Post-Processing Pipeline
A modern Post-Processing Pipeline
 
A new Post-Processing Pipeline
A new Post-Processing PipelineA new Post-Processing Pipeline
A new Post-Processing Pipeline
 
Paris Master Class 2011 - 05 Post-Processing Pipeline
Paris Master Class 2011 - 05 Post-Processing PipelineParis Master Class 2011 - 05 Post-Processing Pipeline
Paris Master Class 2011 - 05 Post-Processing Pipeline
 

More from ozlael ozlael

Unity & VR (Unity Roadshow 2016)
Unity & VR (Unity Roadshow 2016)Unity & VR (Unity Roadshow 2016)
Unity & VR (Unity Roadshow 2016)
ozlael ozlael
 
뭣이 중헌디? 성능 프로파일링도 모름서 - 유니티 성능 프로파일링 가이드 (IGC16)
뭣이 중헌디? 성능 프로파일링도 모름서 - 유니티 성능 프로파일링 가이드 (IGC16)뭣이 중헌디? 성능 프로파일링도 모름서 - 유니티 성능 프로파일링 가이드 (IGC16)
뭣이 중헌디? 성능 프로파일링도 모름서 - 유니티 성능 프로파일링 가이드 (IGC16)
ozlael ozlael
 
Optimizing mobile applications - Ian Dundore, Mark Harkness
Optimizing mobile applications - Ian Dundore, Mark HarknessOptimizing mobile applications - Ian Dundore, Mark Harkness
Optimizing mobile applications - Ian Dundore, Mark Harkness
ozlael ozlael
 
그래픽 최적화로 가...가버렷! (부제: 배치! 배칭을 보자!) , Batch! Let's take a look at Batching! -...
그래픽 최적화로 가...가버렷! (부제: 배치! 배칭을 보자!) , Batch! Let's take a look at Batching! -...그래픽 최적화로 가...가버렷! (부제: 배치! 배칭을 보자!) , Batch! Let's take a look at Batching! -...
그래픽 최적화로 가...가버렷! (부제: 배치! 배칭을 보자!) , Batch! Let's take a look at Batching! -...
ozlael ozlael
 
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) Unite Seoul Ver.
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) Unite Seoul Ver.유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) Unite Seoul Ver.
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) Unite Seoul Ver.
ozlael ozlael
 
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) NDC15 Ver.
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) NDC15 Ver.유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) NDC15 Ver.
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) NDC15 Ver.
ozlael ozlael
 
Infinity Blade and beyond
Infinity Blade and beyondInfinity Blade and beyond
Infinity Blade and beyond
ozlael ozlael
 
스티브잡스처럼 프레젠테이션하기
스티브잡스처럼 프레젠테이션하기스티브잡스처럼 프레젠테이션하기
스티브잡스처럼 프레젠테이션하기
ozlael ozlael
 
유니티의 라이팅이 안 이쁘다구요? (A to Z of Lighting)
유니티의 라이팅이 안 이쁘다구요? (A to Z of Lighting)유니티의 라이팅이 안 이쁘다구요? (A to Z of Lighting)
유니티의 라이팅이 안 이쁘다구요? (A to Z of Lighting)
ozlael ozlael
 
Introduce coco2dx with cookingstar
Introduce coco2dx with cookingstarIntroduce coco2dx with cookingstar
Introduce coco2dx with cookingstarozlael ozlael
 
Deferred rendering case study
Deferred rendering case studyDeferred rendering case study
Deferred rendering case studyozlael ozlael
 
Kgc make stereo game on pc
Kgc make stereo game on pcKgc make stereo game on pc
Kgc make stereo game on pcozlael ozlael
 
Modern gpu optimize blog
Modern gpu optimize blogModern gpu optimize blog
Modern gpu optimize blog
ozlael ozlael
 
Modern gpu optimize
Modern gpu optimizeModern gpu optimize
Modern gpu optimize
ozlael ozlael
 
Bickerstaff benson making3d games on the playstation3
Bickerstaff benson making3d games on the playstation3Bickerstaff benson making3d games on the playstation3
Bickerstaff benson making3d games on the playstation3
ozlael ozlael
 
DOF Depth of Field
DOF Depth of FieldDOF Depth of Field
DOF Depth of Field
ozlael ozlael
 
Hable uncharted2(siggraph%202010%20 advanced%20realtime%20rendering%20course)
Hable uncharted2(siggraph%202010%20 advanced%20realtime%20rendering%20course)Hable uncharted2(siggraph%202010%20 advanced%20realtime%20rendering%20course)
Hable uncharted2(siggraph%202010%20 advanced%20realtime%20rendering%20course)
ozlael ozlael
 
Deferred rendering in_leadwerks_engine[1]
Deferred rendering in_leadwerks_engine[1]Deferred rendering in_leadwerks_engine[1]
Deferred rendering in_leadwerks_engine[1]
ozlael ozlael
 

More from ozlael ozlael (20)

Unity & VR (Unity Roadshow 2016)
Unity & VR (Unity Roadshow 2016)Unity & VR (Unity Roadshow 2016)
Unity & VR (Unity Roadshow 2016)
 
뭣이 중헌디? 성능 프로파일링도 모름서 - 유니티 성능 프로파일링 가이드 (IGC16)
뭣이 중헌디? 성능 프로파일링도 모름서 - 유니티 성능 프로파일링 가이드 (IGC16)뭣이 중헌디? 성능 프로파일링도 모름서 - 유니티 성능 프로파일링 가이드 (IGC16)
뭣이 중헌디? 성능 프로파일링도 모름서 - 유니티 성능 프로파일링 가이드 (IGC16)
 
Optimizing mobile applications - Ian Dundore, Mark Harkness
Optimizing mobile applications - Ian Dundore, Mark HarknessOptimizing mobile applications - Ian Dundore, Mark Harkness
Optimizing mobile applications - Ian Dundore, Mark Harkness
 
그래픽 최적화로 가...가버렷! (부제: 배치! 배칭을 보자!) , Batch! Let's take a look at Batching! -...
그래픽 최적화로 가...가버렷! (부제: 배치! 배칭을 보자!) , Batch! Let's take a look at Batching! -...그래픽 최적화로 가...가버렷! (부제: 배치! 배칭을 보자!) , Batch! Let's take a look at Batching! -...
그래픽 최적화로 가...가버렷! (부제: 배치! 배칭을 보자!) , Batch! Let's take a look at Batching! -...
 
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) Unite Seoul Ver.
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) Unite Seoul Ver.유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) Unite Seoul Ver.
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) Unite Seoul Ver.
 
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) NDC15 Ver.
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) NDC15 Ver.유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) NDC15 Ver.
유니티 그래픽 최적화, 어디까지 해봤니 (Optimizing Unity Graphics) NDC15 Ver.
 
Infinity Blade and beyond
Infinity Blade and beyondInfinity Blade and beyond
Infinity Blade and beyond
 
스티브잡스처럼 프레젠테이션하기
스티브잡스처럼 프레젠테이션하기스티브잡스처럼 프레젠테이션하기
스티브잡스처럼 프레젠테이션하기
 
유니티의 라이팅이 안 이쁘다구요? (A to Z of Lighting)
유니티의 라이팅이 안 이쁘다구요? (A to Z of Lighting)유니티의 라이팅이 안 이쁘다구요? (A to Z of Lighting)
유니티의 라이팅이 안 이쁘다구요? (A to Z of Lighting)
 
Introduce coco2dx with cookingstar
Introduce coco2dx with cookingstarIntroduce coco2dx with cookingstar
Introduce coco2dx with cookingstar
 
Deferred rendering case study
Deferred rendering case studyDeferred rendering case study
Deferred rendering case study
 
Kgc make stereo game on pc
Kgc make stereo game on pcKgc make stereo game on pc
Kgc make stereo game on pc
 
mssao presentation
mssao presentationmssao presentation
mssao presentation
 
Modern gpu optimize blog
Modern gpu optimize blogModern gpu optimize blog
Modern gpu optimize blog
 
Modern gpu optimize
Modern gpu optimizeModern gpu optimize
Modern gpu optimize
 
Bickerstaff benson making3d games on the playstation3
Bickerstaff benson making3d games on the playstation3Bickerstaff benson making3d games on the playstation3
Bickerstaff benson making3d games on the playstation3
 
DOF Depth of Field
DOF Depth of FieldDOF Depth of Field
DOF Depth of Field
 
Hable uncharted2(siggraph%202010%20 advanced%20realtime%20rendering%20course)
Hable uncharted2(siggraph%202010%20 advanced%20realtime%20rendering%20course)Hable uncharted2(siggraph%202010%20 advanced%20realtime%20rendering%20course)
Hable uncharted2(siggraph%202010%20 advanced%20realtime%20rendering%20course)
 
Deferred rendering in_leadwerks_engine[1]
Deferred rendering in_leadwerks_engine[1]Deferred rendering in_leadwerks_engine[1]
Deferred rendering in_leadwerks_engine[1]
 
Ssao
SsaoSsao
Ssao
 

Recently uploaded

IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxIOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
Abida Shariff
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
Thijs Feryn
 
Search and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical FuturesSearch and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical Futures
Bhaskar Mitra
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
Product School
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
Jemma Hussein Allen
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
DanBrown980551
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
UiPathCommunity
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
Cheryl Hung
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
BookNet Canada
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Product School
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
Prayukth K V
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
ThousandEyes
 
ODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User GroupODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User Group
CatarinaPereira64715
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and Grafana
RTTS
 
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdfSmart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
91mobiles
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
Product School
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Product School
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a button
DianaGray10
 

Recently uploaded (20)

IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptxIOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
IOS-PENTESTING-BEGINNERS-PRACTICAL-GUIDE-.pptx
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
 
Search and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical FuturesSearch and Society: Reimagining Information Access for Radical Futures
Search and Society: Reimagining Information Access for Radical Futures
 
How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...How world-class product teams are winning in the AI era by CEO and Founder, P...
How world-class product teams are winning in the AI era by CEO and Founder, P...
 
The Future of Platform Engineering
The Future of Platform EngineeringThe Future of Platform Engineering
The Future of Platform Engineering
 
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
LF Energy Webinar: Electrical Grid Modelling and Simulation Through PowSyBl -...
 
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
Dev Dives: Train smarter, not harder – active learning and UiPath LLMs for do...
 
Key Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdfKey Trends Shaping the Future of Infrastructure.pdf
Key Trends Shaping the Future of Infrastructure.pdf
 
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...Transcript: Selling digital books in 2024: Insights from industry leaders - T...
Transcript: Selling digital books in 2024: Insights from industry leaders - T...
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
Assuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyesAssuring Contact Center Experiences for Your Customers With ThousandEyes
Assuring Contact Center Experiences for Your Customers With ThousandEyes
 
ODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User GroupODC, Data Fabric and Architecture User Group
ODC, Data Fabric and Architecture User Group
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and Grafana
 
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdfSmart TV Buyer Insights Survey 2024 by 91mobiles.pdf
Smart TV Buyer Insights Survey 2024 by 91mobiles.pdf
 
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
De-mystifying Zero to One: Design Informed Techniques for Greenfield Innovati...
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
 
Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...Mission to Decommission: Importance of Decommissioning Products to Increase E...
Mission to Decommission: Importance of Decommissioning Products to Increase E...
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a button
 

Deferred shading

  • 1. Deferred Shading Shawn Hargreaves
  • 2. Overview • Don’t bother with any lighting while drawing scene geometry • Render to a “fat” framebuffer format, using multiple rendertargets to store data such as the position and normal of each pixel • Apply lighting as a 2D postprocess, using these buffers as input
  • 3. Comparison: Single Pass Lighting For each object: Render mesh, applying all lights in one shader • Good for scenes with small numbers of lights (eg. outdoor sunlight) • Difficult to organize if there are many lights • Easy to overflow shader length limitations
  • 4. Comparison: Multipass Lighting For each light: For each object affected by the light: framebuffer += object * light • Worst case complexity is num_objects * num_lights • Sorting by light or by object are mutually exclusive: hard to maintain good batching • Ideally the scene should be split exactly along light boundaries, but getting this right for dynamic lights can be a lot of CPU work
  • 5. Deferred Shading For each object: Render to multiple targets For each light: Apply light as a 2D postprocess • Worst case complexity is num_objects + num_lights • Perfect batching • Many small lights are just as cheap as a few big ones
  • 6. Multiple Render Targets • Required outputs from the geometry rendering are: – Position – Normal – Material parameters (diffuse color, emissive, specular amount, specular power, etc) • This is not good if your lighting needs many input values! (spherical harmonics would be difficult)
  • 7. Fat Framebuffers • The obvious rendertarget layout goes something like: – Position A32B32G32R32F – Normal A16B16G16R16F – Diffuse color A8R8G8B8 – Material parameters A8R8G8B8 • This adds up to 256 bits per pixel. At 1024x768, that is 24 meg, even without antialiasing! • Also, current hardware doesn’t support mixing different bit depths for multiple rendertargets
  • 8. Framebuffer Size Optimizations • Store normals in A2R10G10B10 format • Material attributes could be palettized, then looked up in shader constants or a texture • No need to store position as a vector3: – Each 2D screen pixel corresponds to a ray from the eyepoint into the 3D world (think raytracing) – You inherently know the 2D position of each screen pixel, and you know the camera settings – So if you write out the distance along this ray, you can reconstruct the original worldspace position
  • 9. My Framebuffer Choices • 128 bits per pixel = 12 meg @ 1024x768: – Depth R32F – Normal + scattering A2R10G10B10 – Diffuse color + emissive A8R8G8B8 – Other material parameters A8R8G8B8 • My material parameters are specular intensity, specular power, occlusion factor, and shadow amount. I store a 2-bit subsurface scattering control in the alpha channel of the normal buffer
  • 14. How Wasteful… • One of my 32 bit buffers holds depth values • But the hardware is already doing this for me! • It would be nice if there was an efficient way to get access to the existing contents of the Z buffer • Pretty please? ☺
  • 15. Global Lights • Things like sunlight and fog affect the entire scene • Draw them as a fullscreen quad • Position, normal, color, and material settings are read from texture inputs • Lighting calculation is evaluated in the pixel shader • Output goes to an intermediate lighting buffer
  • 16. Local Lights • These only affect part of the scene • We only want to render to the affected pixels • This requires projecting the light volume into screenspace. The GPU is very good at that sort of thing… • At author time, build a simple mesh that bounds the area affected by the light. At runtime, draw this in 3D space, running your lighting shader over each pixel that it covers
  • 17. Convex Light Hulls • The light bounding mesh will have two sides, but it is important that each pixel only gets lit once • As long as the mesh is convex, backface culling can take care of this
  • 18. Convex Light Hulls • The light bounding mesh will have two sides, but it is important that each pixel only gets lit once • As long as the mesh is convex, backface culling can take care of this
  • 19. Convex Light Hulls #2 • If the camera is inside the light volume, draw backfaces
  • 20. Convex Light Hulls #3 • If the light volume intersects the far clip plane, draw frontfaces • If the light volume intersects both near and far clip planes, your light is too big!
  • 21. Volume Optimization • We only want to shade the area where the light volume intersects scene geometry • There is no need to shade where the volume is suspended in midair • Or where it is buried beneath the ground
  • 22. Stencil Light Volumes • This is exactly the same problem as finding the intersection between scene geometry and an extruded shadow volume • The standard stencil buffer solution applies • But using stencil requires changing renderstate for each light, which prevents batching up multiple lights into a single draw call • Using stencil may or may not be a performance win, depending on context
  • 23. Light Volume Z Tests • A simple Z test can get things half-right, without the overhead of using stencil • When drawing light volume backfaces, use D3DCMP_GREATER to reject “floating in the air” portions of the light
  • 24. Light Volume Z Tests #2 • If drawing frontfaces, use D3DCMP_LESS to reject “buried underground” light regions • Which is faster depends on the ratio of aboveground vs. underground pixels: use a heuristic to make a guess
  • 25. Alpha Blending • This is a big problem! • You could simply not do any lighting on alpha blended things, and draw them after the deferred shading is complete. The emissive and occlusion material controls are useful for crossfading between lit and non-lit geometry • The return of stippling? • Depth peeling is the ultimate solution, but is prohibitively expensive at least for the time being
  • 26. High Dynamic Range • You can do deferred shading without HDR, but that wouldn’t be so much fun • Render your scene to multiple 32 bit buffers, then use a 64 bit accumulation buffer during the lighting phase • Unfortunately, current hardware doesn’t support additive blending into 64 bit rendertargets • Workaround: use a pair of HDR buffers, and simulate alpha blending in the pixel shader
  • 27. DIY Alpha Blending • Initialize buffers A and B to the same contents • Set buffer A as a shader input, while rendering to B, and roll your own blend at the end of the shader • This only works as long as your geometry doesn’t overlap in screenspace • When things do overlap, you have to copy all modified pixels from B back into A, to make sure the input and output buffers stay in sync • This is slow, but not totally impractical as long as you sort your lights to minimize screenspace overlaps
  • 29. Volumetric Depth Tests • Neat side effect of having scene depth available as a shader input • Gradually fade out alpha as a polygon approaches the Z fail threshold • No more hard edges where alpha blended particles intersect world geometry!
  • 30. Deferred Shading Advantages • Excellent batching • Render each triangle exactly once • Shade each visible pixel exactly once • Easy to add new types of lighting shader • Other kinds of postprocessing (blur, heathaze) are just special lights, and fit neatly into the existing framework
  • 31. The Dark Side • Alpha blending is a nightmare! • Framebuffer bandwidth can easily get out of hand • Can’t take advantage of hardware multisampling • Forces a single lighting model across the entire scene (everything has to be 100% per-pixel) • Not a good approach for older hardware • But will be increasingly attractive in the future…
  • 32. The End • Any questions?