Epic: visibility-buffer opaque pipeline (explore for FPS) #256
Labels
No labels
amd
avatars
bug
builder
cannot-reproduce
crash
epic
feature
from-viewer
gl-removal
known-limitation
monitoring
parity
perf
platform
priority
critical
priority
high
priority
low
priority
medium
provenance
rendering
rt
status
in-progress
status
testing
status
up-next
triage
ui
upstream
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
sky_line/Slipstream#256
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Epic — exploratory, no timeline. Track a visibility-buffer (VB) opaque pipeline as a future option for more FPS, mainly in dense, zoomed-out multi-sim views.
Why
Our opaque path is GPU-driven deferred: compute cull, then multi-draw indirect into a G-buffer, then compute lighting (
clean_deferred_light.comp). That's already per-pixel for lighting. The remaining costs grow with geometry complexity:A VB pass writes only
instanceID + triangleID(about 4–8 B per pixel), which makes the geometry pass almost free per pixel. Material evaluation and lighting then run exactly once per visible pixel, in compute. This is the approach Nanite and other modern GPU-driven engines take for dense geometry.Sketch
uint(instance/draw id + primitive id) plus depth. There's no material work in this pass; it doesn't fetch textures except for alpha-masked geometry, which is a separate pass or binned.Open questions / risks
Exit criteria (for exploring)
Analysis 2026-10-10 (after the #259 prepass A/B)
Geometry passes today: busy sim, prepass ON, RTX 5090 at 4K with FSR, GPU 10.7 ms total.
g_prepass0.83,g_gbuf_static1.25,g_gbuf_rigged~0.25, so about 2.3 ms.Expected gain here: a visibility-buffer raster pass costs about what the prepass does (~0.8 ms), plus a compute material resolve (~0.5-1 ms at 4K, estimate). Net gain in this scene is ~0.5-1 ms.
Why that's modest: the prepass already gives one material evaluation per visible pixel (EQUAL test). What a visibility buffer adds on top:
Gate: take one GPU timer sample in a dense, zoomed-out multi-sim view (mainland or a big build from above, high draw distance, prepass ON).
Order: remove the forward fallback (#640) first or as part of this, so only one world path needs converting.
The A/B behind this is in #259.