Shadow maps: near-parity with ray-traced shadows at max projector budget (static caching, caster culling, multiview, filtering) #567
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#567
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?
Goal: shadow-map shadows (the path for GPUs without ray tracing, and the fallback) should cost close to the ray-traced path, even at the maximum projector budget.
Baseline (2026-10-08, owner's machine RTX 5090, static scene with 16 projectors, after #564's per-view rigged cull + caster LOD):
c_shadowsc_projshadowTarget: shadow-map overhead under about 1–1.5 ms over RT at 16 and 32 projectors, without visible quality loss near the camera. Same rules as before: adaptive and targeted, no global cuts, and the user's resolution setting is never changed.
Directions to evaluate (measure each):
Done when: the A/B above (and at max projector budget) shows maps within ~1–1.5 ms of RT, with documented quality comparisons.
Started 2026-10-10. Fresh owner measurement: RTX 5090, 4K with FSR, busy sim, 32 projectors shadowed.
Maps cost ~+4 ms for sun/moon and ~+12 ms with 32 projectors, over RT.
Order of work:
Correction 2026-10-10: the baseline table above mis-attributed the sun cost
Re-reading the log (11:26-11:29), the "all ray traced ~90 fps / 10.8 ms" row had no sun shadow at all: the sun switched on at 11:27:32.
projTilesRendered=32 projTilesCached=0 projDirtLight=12 projDirtChanged=20every frame.c_shadowshas a ~1.9 ms floor even with no cascades (likely a cross-queue wait), so it isn't a reliable measure of cascade cost.Work merged:
Expected projector steady state ~3-4 ms; the next step depends on
c_proj_cullvsg_proj_staticin the new counters.Shipped in 1.3.0 Beta 2: projector static/dynamic caster split, event-driven tile and cascade caches, invalidation from the instance store, sub-texel caster cull. Sun cascades are already within target. Still to do: re-measure projector tiles at 16 and 32 projectors (expected ~3-4 ms), then GPU per-tile static caster cull and the filtering cost if the numbers still miss the 1-1.5 ms target.
Follow-up item (2026-10-14 status audit): the event-driven cascade cache (RenderVKShadowEventCache + static/dynamic split + instance-store invalidation) only runs with
RenderVKShadowUpdate1/2; the default is 0 (Realtime: all 4 cascades every frame, static layers freed). Evaluate making the event-driven cache the default (or auto-selected) for shadow-map users, after an A/B of quality (texel-step swimming, light-move threshold) and GPU ms on a static and a busy scene.