Computer Graphics

Real-Time Shading

Getting a usable approximation of the above inside a frame budget.

Colour is the family; a dashed line is the second member of it.

Drag to pan · scroll to zoom · click a node to open it · hover one for the reasons on its edges, and to bring it forward
G ambient-occlusion Ambient Occlusion rendering-equation The Rendering Equation ambient-occlusion->rendering-equation clustered-shading Clustered / Tiled Shading deferred-shading Deferred Shading clustered-shading->deferred-shading ddgi Dynamic Diffuse Global Illumination light-probes Irradiance Probes ddgi->light-probes forward-shading Forward Shading deferred-shading->forward-shading rasterization Rasterization forward-shading->rasterization gbuffer G-Buffer gbuffer->deferred-shading gtao Ground-Truth Ambient Occlusion hbao Horizon-Based Ambient Occlusion gtao->hbao ssao Screen-Space Ambient Occlusion hbao->ssao image-based-lighting Image-Based Lighting image-based-lighting->rendering-equation irradiance-caching Irradiance Caching light-probes->irradiance-caching lightmaps Lightmaps radiosity Radiosity lightmaps->radiosity linearly-transformed-cosines Linearly Transformed Cosines microfacet-model Microfacet Model linearly-transformed-cosines->microfacet-model prefiltered-environment-map Prefiltered Environment Map prefiltered-environment-map->image-based-lighting screen-space-reflections Screen-Space Reflections specular-reflection Specular Reflection screen-space-reflections->specular-reflection spherical-harmonics Spherical Harmonics Irradiance spherical-harmonics->image-based-lighting split-sum-approximation Split-Sum Approximation split-sum-approximation->prefiltered-environment-map split-sum-approximation->microfacet-model ssao->ambient-occlusion visibility-buffer Visibility Buffer visibility-buffer->deferred-shading
The 19 reasons on these edges, as text

18 nodes

Spherical Harmonics Irradiance

Projects distant lighting onto low-order spherical harmonics. Nine coefficients reproduce diffuse irradiance from any environment to within a percent… · 2001

Screen-Space Ambient Occlusion

Estimates occlusion by sampling the depth buffer around each pixel, making ambient occlusion fully dynamic and independent of scene complexity. · 2007

Horizon-Based Ambient Occlusion

Marches the depth buffer to find the horizon angle in several directions and integrates the unoccluded wedge, which is a defensible approximation of… · 2008

Clustered / Tiled Shading

Bins lights into screen tiles or view-space froxels so each pixel iterates only the lights that can reach it, making thousands of local lights afford… · 2012

Split-Sum Approximation

Factors the specular IBL integral into a prefiltered radiance lookup times a precomputed BRDF response table. Both halves fit in textures, which is w… · 2013

Visibility Buffer

Stores only a triangle id per pixel and refetches attributes during shading, trading arithmetic for a dramatic reduction in the memory traffic a fat… · 2013

Ground-Truth Ambient Occlusion

Reformulates horizon-based occlusion with the correct cosine weighting and normalization so it converges to reference ambient occlusion instead of a… · 2016

Linearly Transformed Cosines

Represents a GGX lobe as a linear transform of a clamped cosine, and cosines can be integrated over a polygon in closed form. Turns area- light shadi… · 2016

Dynamic Diffuse Global Illumination

Stores filtered depth alongside irradiance at each probe and weights probe contributions by a visibility test, so a probe on the far side of a wall s… · 2019

Ambient Occlusion

A scalar factor for how much of the hemisphere above a point is blocked by nearby geometry, multiplied into ambient light. Not physically justified,…

Deferred Shading

Rasterize surface attributes into a G-buffer first, then light every visible pixel exactly once in a full-screen pass. Decouples lighting cost from s…

Forward Shading

Shade each fragment as its triangle is rasterized, looping over lights inside the shader. Simple and MSAA-friendly, but cost is paid again for every…

G-Buffer

The set of screen-space textures holding albedo, normal, roughness and depth between the geometry pass and the lighting pass.

Image-Based Lighting

Uses a captured or rendered environment map as the light source, so that ambient light carries the colour and directionality of a real location.

Irradiance Probes

Samples indirect irradiance at a grid of points and interpolates between them for dynamic objects, decoupling indirect lighting cost from the number…

Lightmaps

Bakes static indirect lighting into textures parameterized over surfaces. Still the highest-quality option for static geometry, at the cost of build…

Prefiltered Environment Map

Convolves the environment map against the BRDF lobe ahead of time, storing successively rougher versions in mip levels so a runtime lookup replaces a…

Screen-Space Reflections

Ray-marches the depth buffer to find reflected surfaces. Convincing while the reflected geometry is on screen, and falls back to an environment map t…