[Epic] Ambient occlusion tiers: GTAO (screen-space, replaces SSAO) + ray-traced AO (RTAO) #86

Open
opened 2026-09-27 05:44:58 +00:00 by sky_line · 2 comments
Owner

Goal: best-available ambient occlusion per hardware tier, all writing the same AO target that the lit pass applies to ambient/probe light (not direct light):

  • RTAO on ray-tracing GPUs: true occlusion, including off-screen and hidden occluders.
  • GTAO (Ground-Truth AO, Jimenez et al. 2016) as the screen-space tier for GPUs without RT. It replaces the LL-parity 8-tap SSAO, which stays available for comparison.

Status (2026-10-10)

  • Done: the consumer side. clean_ao.comp writes the shared AO target (LL-parity SSAO, 8 taps plus LL's blur, with geometric-normal / contact-slope / strength options). The lit pass reads it; RenderVKAOStandard selects standard vs LL-parity application. It runs async next to the RT shadow mask (q_mask_ao).
  • In progress: GTAO as a live-switchable method (RenderVKAOMethod: 0 = SSAO, 1 = GTAO) for an in-world A/B against SSAO, with its own GPU timer marks.
  • Later: RTAO.

GTAO (part 1)

  • Per pixel: N rotated slices, a screen-space horizon search within a world-space radius, then the analytic cosine-weighted visibility integral around the projected normal.
  • Optional: thickness heuristic, multi-bounce approximation, half-res option.
  • Writes the same AO target, so the blur and the consumer are unchanged.
  • A/B in-world: creases, flat-surface self-occlusion (SSAO greys flat floors), halos at depth edges, avatar contact shadows; cost from the GPU timers.
  • Becomes the non-RT tier (#98 hardware tiers).

RTAO (part 2, later)

  • Trace: half-res, 1 cosine-weighted ray/pixel, short radius (0.5-2 m), first-hit termination. It runs inside the async RT shadow-mask dispatch as an extra channel (shared setup); alpha-mask occluders go through the candidate loop and opacity micromaps.
  • Denoise: temporal (history, reprojection with the existing motion vectors, reactive term for animated avatars) plus spatial; reuse the shadow SVGF stages, adapted to the AO signal. Then a bilateral upsample.
  • Settings: RenderVKAOMethod 2 = RT, default on RT-capable GPUs once tuned. Radius/strength shared.
  • Expected cost on a 5090 at 4K: ~0.4-0.8 ms trace + ~0.3 ms denoise, mostly overlapped on the async queue.
  • A/B against GTAO, which is the right baseline.

Relates: #21 SSAO, #85 denoiser epic, #98 hardware tiers.

**Goal:** best-available ambient occlusion per hardware tier, all writing the same AO target that the lit pass applies to ambient/probe light (not direct light): - **RTAO** on ray-tracing GPUs: true occlusion, including off-screen and hidden occluders. - **GTAO** (Ground-Truth AO, Jimenez et al. 2016) as the screen-space tier for GPUs without RT. It replaces the LL-parity 8-tap SSAO, which stays available for comparison. ### Status (2026-10-10) - **Done:** the consumer side. `clean_ao.comp` writes the shared AO target (LL-parity SSAO, 8 taps plus LL's blur, with geometric-normal / contact-slope / strength options). The lit pass reads it; `RenderVKAOStandard` selects standard vs LL-parity application. It runs async next to the RT shadow mask (`q_mask_ao`). - **In progress:** **GTAO** as a live-switchable method (`RenderVKAOMethod`: 0 = SSAO, 1 = GTAO) for an in-world A/B against SSAO, with its own GPU timer marks. - **Later:** **RTAO**. ### GTAO (part 1) - **Per pixel:** N rotated slices, a screen-space horizon search within a world-space radius, then the analytic cosine-weighted visibility integral around the projected normal. - **Optional:** thickness heuristic, multi-bounce approximation, half-res option. - Writes the same AO target, so the blur and the consumer are unchanged. - **A/B in-world:** creases, flat-surface self-occlusion (SSAO greys flat floors), halos at depth edges, avatar contact shadows; cost from the GPU timers. - Becomes the non-RT tier (#98 hardware tiers). ### RTAO (part 2, later) - **Trace:** half-res, 1 cosine-weighted ray/pixel, short radius (0.5-2 m), first-hit termination. It runs inside the async RT shadow-mask dispatch as an extra channel (shared setup); alpha-mask occluders go through the candidate loop and opacity micromaps. - **Denoise:** temporal (history, reprojection with the existing motion vectors, reactive term for animated avatars) plus spatial; reuse the shadow SVGF stages, adapted to the AO signal. Then a bilateral upsample. - **Settings:** `RenderVKAOMethod` 2 = RT, default on RT-capable GPUs once tuned. Radius/strength shared. - **Expected cost** on a 5090 at 4K: ~0.4-0.8 ms trace + ~0.3 ms denoise, mostly overlapped on the async queue. - **A/B against GTAO**, which is the right baseline. **Relates:** #21 SSAO, #85 denoiser epic, #98 hardware tiers.
sky_line added this to the Slipstream project 2026-10-06 15:04:15 +00:00
sky_line changed title from [Epic] Ray-traced ambient occlusion (SSAO fallback) to [Epic] Ambient occlusion tiers: GTAO (screen-space, replaces SSAO) + ray-traced AO (RTAO) 2026-10-10 11:24:19 +00:00
Author
Owner

Started 2026-10-10 with part 1, GTAO as a live-switchable method for an A/B against the current SSAO. RTAO (part 2) comes later.

Started 2026-10-10 with part 1, GTAO as a live-switchable method for an A/B against the current SSAO. RTAO (part 2) comes later.
Author
Owner

GTAO shipped in 1.3.0 Beta 2 (RenderVKAOMethod, SSAO or GTAO). The ray-traced AO part (RTAO) is not started, so this epic goes back to the backlog until that is picked up.

GTAO shipped in 1.3.0 Beta 2 (RenderVKAOMethod, SSAO or GTAO). The ray-traced AO part (RTAO) is not started, so this epic goes back to the backlog until that is picked up.
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
sky_line/Slipstream#86
No description provided.