Probe captures: capture-only forward shader (no RT/SSR/mirror/debug) + light grid #829

Closed
opened 2026-10-17 21:14:16 +00:00 by sky_line · 2 comments
Owner

Reflection probe captures draw with the full forward lit shader, which is register-heavy and carries features a probe face never needs.

Measured:

  • GTX 1080, 4K, high settings: capture work is about 4.3 ms per frame: pr_rt_face 1.51, pr_face 0.67, pr_cull + pr_rt_cull 1.27, pr_rt_alpha 0.44, pr_patch 0.38. About 2.1 ms at Firestorm-equivalent.
  • RTX 5090 registers: forward lit FS ("spec lit") 168 registers plain and 255 with ray query (FragRt); particles 168.
  • GTX 1080: the forward lit FS is likewise the heaviest graphics shader.

A capture face is 128 px over 90 degrees (each pixel is metres wide), filtered and mip-mapped afterwards. It does not need SSR, mirrors, ray-query shadows, the debug views, TAA bias, or full per-pixel local-light loops.

Plan

  1. Capture-only forward FS variant (compile-time defines, like the G-buffer terrain split #813), with features off:
    • SSR / mirror sampling;
    • ray-query shadows: use the shadow maps or none;
    • debug views;
    • forward-only extras.
      It gets its own pipelines for the probe-face draws (opaque / mask / ds / alpha); the main-view forward pipelines stay as they are.
  2. Local lights in captures: use the froxel / tile light grid (as #817 proposes for forward alpha), or cap captures to the nearest N lights. Decide by image difference at probe resolution.
  3. Check whether probe culls (pr_cull, pr_rt_cull, pr_patch; 1.3 ms) can share the main cull's results or run at lower granularity.
  4. Keep the old path behind a setting for A/B.

Measure

Registers of the new variants (RenderVKPipelineStats); a probe image A/B (filtered cube faces) old vs new; serial A/B of the pr_* passes and the frame total on the GTX 1080 (Firestorm-equivalent and high) and the RTX 5090. Expected 1-2 ms on Pascal at high, also lower on RT cards (255 -> much less).

Reflection probe captures draw with the full forward lit shader, which is register-heavy and carries features a probe face never needs. **Measured:** - **GTX 1080, 4K, high settings:** capture work is about 4.3 ms per frame: `pr_rt_face` 1.51, `pr_face` 0.67, `pr_cull` + `pr_rt_cull` 1.27, `pr_rt_alpha` 0.44, `pr_patch` 0.38. About 2.1 ms at Firestorm-equivalent. - **RTX 5090 registers:** forward lit FS ("spec lit") 168 registers plain and **255 with ray query** (`FragRt`); particles 168. - **GTX 1080:** the forward lit FS is likewise the heaviest graphics shader. A capture face is 128 px over 90 degrees (each pixel is metres wide), filtered and mip-mapped afterwards. It does not need SSR, mirrors, ray-query shadows, the debug views, TAA bias, or full per-pixel local-light loops. ### Plan 1. **Capture-only forward FS variant** (compile-time defines, like the G-buffer terrain split #813), with features off: - SSR / mirror sampling; - ray-query shadows: use the shadow maps or none; - debug views; - forward-only extras. It gets its own pipelines for the probe-face draws (opaque / mask / ds / alpha); the main-view forward pipelines stay as they are. 2. **Local lights in captures:** use the froxel / tile light grid (as #817 proposes for forward alpha), or cap captures to the nearest N lights. Decide by image difference at probe resolution. 3. Check whether probe culls (`pr_cull`, `pr_rt_cull`, `pr_patch`; 1.3 ms) can share the main cull's results or run at lower granularity. 4. Keep the old path behind a setting for A/B. ### Measure Registers of the new variants (`RenderVKPipelineStats`); a probe image A/B (filtered cube faces) old vs new; serial A/B of the `pr_*` passes and the frame total on the GTX 1080 (Firestorm-equivalent and high) and the RTX 5090. Expected 1-2 ms on Pascal at high, also lower on RT cards (255 -> much less).
sky_line added this to the Slipstream project 2026-10-17 21:14:16 +00:00
Author
Owner

Merged (76fbac0ecd, 264f0a6a15). GTX 1080, 4K:

  • Capture FS 142 registers.
  • Capture faces (pr_rt_face): slim on 0.89-0.96 ms vs off 1.48 ms at high, about -0.55 ms. At Firestorm-equivalent 0.51-0.53 ms vs 1.04-1.10 ms in the baseline.
  • Frame totals in that run were noisier than the gain (avatar alpha in view).

The 142 registers are mostly material + sun + atmosphere code, which supports moving opaque captures to the deferred path (48-register G-buffer + #827 BASE). LL / Firestorm capture probes with their deferred pipeline. Decide after a 5090 measurement.

Still to do: probe image A/B (RT-sun shadow edge, more than 16 lights, terrain bake), the 5090 register counts, and the cluster-LOD capture draws, which still use the full FS.

Merged (76fbac0ecd, 264f0a6a15). GTX 1080, 4K: - Capture FS 142 registers. - Capture faces (`pr_rt_face`): slim on 0.89-0.96 ms vs off 1.48 ms at high, about -0.55 ms. At Firestorm-equivalent 0.51-0.53 ms vs 1.04-1.10 ms in the baseline. - Frame totals in that run were noisier than the gain (avatar alpha in view). The 142 registers are mostly material + sun + atmosphere code, which supports moving opaque captures to the deferred path (48-register G-buffer + #827 BASE). LL / Firestorm capture probes with their deferred pipeline. Decide after a 5090 measurement. Still to do: probe image A/B (RT-sun shadow edge, more than 16 lights, terrain bake), the 5090 register counts, and the cluster-LOD capture draws, which still use the full FS.
Author
Owner

Fixed in Slipstream 1.3.0 (stable): https://git.slipstreamviewer.org/sky_line/Slipstream/releases/tag/v1.3.0

If you still see this on 1.3.0, reply here and we'll reopen it.

Fixed in **Slipstream 1.3.0** (stable): https://git.slipstreamviewer.org/sky_line/Slipstream/releases/tag/v1.3.0 If you still see this on 1.3.0, reply here and we'll reopen it.
Sign in to join this conversation.
No milestone
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#829
No description provided.