Game dev
Saved & recent

Ambient occlusion

Also called: AO

Related terms: SSAO

Darkens creases, corners and contact points, where surrounding geometry blocks ambient light from reaching. It grounds objects so they do not look like they float.

It can be painted into a texture ahead of time, or estimated every frame from the depth buffer. The second approach is SSAO, screen-space ambient occlusion.

Further reading
LearnOpenGL: screen-space ambient occlusion
base shading ambient occlusion open pointvisibility 1.00 contact pointvisibility 0.58
Both views share geometry, camera and base shading. The right adds ambient darkening from 128 cosine-weighted world-space rays per surface sample, limited to 1.2 scene units. Visibility is the escaping fraction: 1.00 at the open marker and 74/128 โ‰ˆ 0.58 beside the block. This local approximation omits direct-light cast shadows and bounced illumination.

View in the full Game dev collection