Shadows, sea floor and small surface spots flicker together with a still camera (AMD) #74
Labels
No labels
accessibility
bench-bm-v1
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/PastiiJay--klbf-lab#74
Loading…
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?
@PastiiJay on GitHub · 2026-11-26 11:45 UTC · original
Same machine as #73. With the camera and the player perfectly still, several things flicker at the same moments: a small object's contact shadow, the sea floor seen through the water, and tiny spots of a wooden floor. Because they flicker together, we think it is one cause, probably a screen-space or shadow resource that is sometimes read before it is finished, or from the previous frame. Ideas welcome.
@HandshakeHackin on GitHub · 2026-11-26 11:54 UTC · original
One way to narrow this down on
beta-2is to capture two consecutive presented frames at the fixed camera, one lit and one dark. In a diagnostics build, setVICTORY_CAPTUREto a folder andVICTORY_CAPTURE_FRAMESto the two frame numbers, withVICTORY_DUMP_TARGETS=1. Match the target by dimensions, format and resource in that run. If it alternates between two resources, keep both identities.For a suspected R32_UINT shadow-mask table, compare the
target values as wordsrows, especiallyzeroandall_ones. Those count actual words. The PNGs are scaled per image, so an apparently brighter mask alone is ambiguous. Once you have a candidate writer fromframe-<n>-ops.txt,VICTORY_DUMP_AFTER=<shader hash>takes a copy immediately after its draw or dispatch. If the mask already differs there, focus on its producer and inputs. If the producer outputs match but the displayed patches differ, the later passes are the place to look. Record whether the flicker survives capture, since readbacks add GPU work and transitions. Per-pass capture · Integer mask counters.@PastiiJay on GitHub · 2026-11-26 11:56 UTC · original
Thanks @HandshakeHackin, that's a much better way in than guessing switches. We're building a diagnostics build now and will capture two consecutive frames, one lit and one dark, at the same fixed camera, with
VICTORY_DUMP_TARGETS=1. If a target alternates between two resources, we'll follow it back to its writer withVICTORY_DUMP_AFTER. We'll post what we find here.One extra detail from today: the sea floor keeps the same flicker rhythm whatever we change on the water path, while the sea surface (#73) changes rhythm with
VICTORY_CLAMP_AHEAD=0/VICTORY_INDIRECT_RAW=1. So these look like two separate causes.@PastiiJay on GitHub · 2026-11-26 12:15 UTC · original
Capture results (same still-camera run as #73), and it's a separate cause from the sea, as suspected:
The sand, contact shadow and deck spots all live in the G-buffer albedo (1280x720, R8G8B8A8_TYPELESS), which toggles between two states: one with decals (wet sand, worn rug) and one without (dry sand, plain rug). Within a state the frames differ by 4.5–7.7; across states by 9–17.5. The likely writer is a deferred-decal pass: 64 indirect draws, vertex
167501e87c356551, pixel shaders144249440a4b420etofa3534fe1e406e51. It has no render target and writes the albedo through UAVs, depth-tested, followed by compute565cc0b38920b229. The draw list is identical in both states, so the decals are recorded every frame but their result is lost on some frames. Our guess is submission order, or a missing UAV/RT barrier against the G-buffer lists that overwrite them. Next:VICTORY_DUMP_AFTERon those decal shaders.