Aller au contenu

Ambient Occlusion Node

By Kriss Norde

Ambient Occlusion (AO) generates a global lighting effect on 3D renders as a post effect. It quickly approximates expensive ray-traced global illumination by simulating uniform spherical diffuse lighting. It captures low-frequency lighting (ambient shading areas) without hard shadows or speculars.

Overview

Ambient Occlusion uses the Z-Depth and Normals channels of a 3D render to compute, for each pixel, the amount of ambient light it receives (vs occluded by the surrounding geometry). Result: soft shading in corners, under objects and in creases.

Essential to integrate a 3D render that had no native AO, or to add / strengthen contact shadows in post without launching an expensive re-render.

Where to find this node

  • Effects Library: Tools > Deep Pixel > Ambient Occlusion
  • Quick add: right-click in the Node Editor → Add Tool > Deep Pixel > Ambient Occlusion

What AO is

Principle
For each pixel, rays are cast from its surface (along the normals) into a hemisphere. The number of rays occluded by nearby geometry is counted → occlusion coefficient.
Corners / creases
The rays are occluded → darkening = a natural "contact shadow" under objects, in corners, under furniture, etc.
Open areas
Unobstructed rays → full ambient light = no darkening.
Approximation
Not true ray-traced GI (which accounts for multiple bounces and light sources). But enough for most cases, and much faster.

Inputs

  • Input (orange) - 2D RGBA image + Z-Depth + Normals (from a multilayer EXR).
  • Camera (green) - the Camera 3D or 3D scene that rendered the source image.
  • Effect Mask (blue) - optional. Limits the AO to specific areas.

Setup

AO on a 3D render:
EXR (RGBA + Z + Normals) → Ambient Occlusion (Camera connected)
                         → MediaOut

With Output Mode = AO only:
EXR → Ambient Occlusion (Output Mode = AO)
   → produces a grayscale AO only
   → can be used as a mask for custom grading
   → MediaOut

Multi-pass workflow:
EXR Beauty ─┐
            │
EXR (Z+N) ──┼── Ambient Occlusion (AO mode)
            │           ↓
            └── Multiply with Beauty
                        ↓
                     MediaOut

Combined with Diffuse / Specular:
AO + Diffuse + Specular passes → custom equations
                              = lighting rebuilt in compositing

Controls tab

Output Mode (default: Color)
Color: combines the image with the AO applied. AO: grayscale output only (can be used as a mask).
Kernel Type (default: Hemisphere)
Hemisphere: realistic, recommended. Samples the hemisphere oriented by the normal. Sphere: stylistic (samples all around).
Number of Samples
Increase until the artifacts disappear. More samples = higher quality but slower renders. Typical: 16-64 depending on the scene.
Kernel Radius
3D size of the kernel filter. Crucial: too small misses the occluders, too large lowers the quality. It must be tuned for each scene.
Lift / Gamma / Tint
Artistic controls to adjust the AO. Lift = raises the blacks, Gamma = midtones, Tint = hue (useful for warm / cool AO).

Use cases

  • 3D render without native AO - a fast 3D renderer without GI: Ambient Occlusion in post to add the contact shadow back.
  • Strengthening existing AO - a render with weak AO: add a Fusion AO pass on top for more visual depth.
  • Lighting reconstruction in compositing - combine AO + Diffuse + Specular passes to rebuild the lighting in post with full control.
  • Fast iteration - change the AO intensity without re-rendering the 3D.
  • Mask for grading - Output Mode = AO = a grayscale mask you can use to selectively grade the occluded areas.
  • ArchViz enhancement - architectural renders with post AO = much more visual depth.

Tips

  • Z + Normals are required - without these channels, the node does nothing useful. Enable their AOV export in 3D.
  • The camera must match the render - the connected camera must be the one used for the render. Otherwise the AO is computed incorrectly.
  • Scene-specific Kernel Radius - there is no universal value. Adapt it to the scale of the scene (m / cm / units). "Rarely right out of the box".
  • Samples 16-32 = sweet spot - start at 16, raise it to 32-64 if artifacts are visible. Beyond that = a waste of time.
  • Hemisphere for realism - Sphere only for a stylistic effect. Hemisphere = the standard.
  • Output Mode AO + multiply - for finer control:AO output → Channel Booleans (Multiply) with Beauty = AO you can apply separately.
  • Tint for matching - slightly tinted AO (e.g. bluish for cool scenes, yellowish for warm scenes) = more organic integration.
  • For very complex renders (dense geometry), prefer a native 3D AO at render time - Fusion's AO is an approximation, not a replacement.