Reflections: the alpha layer's miss program runs again (blocks on glass) #2534

Closed
unueberlegt wants to merge 1 commit from upstream-pr/2534 into main
unueberlegt commented 2026-11-29 13:55:06 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by unueberlegt on 2026-11-29T13:55:06Z.


What this changes

The reflections' miss program is left out only for opaque surfaces now. The alpha layer's (glass) runs again, kept as water's is. The opaque skip that fixed the white grain on floors stays.

Why

e2d7854e left the program out for opaque and transparent surfaces, keeping only water's running, "without them its reflections hold earlier frames' bytes". Glass is the same case: its screen-space march rarely resolves what it looks at. With the program left out, a window's unresolved rays have no fill at all — no sky (the skip), and no estimate either (ambient(Role::Miss) never runs; the skip returns before it) — so the reflection target holds earlier frames' bytes: flickering rectangular red/green/blue/purple blocks, #2440's screenshots.

Why it only appeared between f9dfb76 and 829188e9

The skip has been in the tree since e2d7854e, which f9dfb76 already contains. But its surface-layer lookup only resolves the miss program's first root constant since the root bindings of #1204 changed the slots — on f9dfb76 the lookup failed, every dispatch ran the program, and glass was given the sky. #2440's own logs confirm it: the f9dfb76 session has no "miss program left out" line (the program ran); on 829188e9 it fires in every stock run. Their run matrix agrees: the three runs where the line fired show the blocks, the three VICTORY_RAYMISS_KEEP=1 runs (line absent) show clean windows.

VICTORY_RAYMISS_KEEP=1 stays the escape hatch for everything, as before.

Testing

  • New miss_program_kept_tests::only_opaque_is_left_out: opaque left out (the white-grain fix), alpha and water kept, an unknown layer runs the program.
  • cargo test -p victory-gpu --lib: 915 passed, one failure (a_change_is_saved_at_once) is the known parallel-run flake class, 2/2 green in isolation.

Fixes #2440

🤖 Generated with Claude Code

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:issue:5551395074 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/2534). Originally posted by [unueberlegt](https://github.com/unueberlegt) on 2026-11-29T13:55:06Z. --- ## What this changes The reflections' miss program is left out only for **opaque** surfaces now. The alpha layer's (glass) runs again, kept as water's is. The opaque skip that fixed the white grain on floors stays. ## Why e2d7854e left the program out for opaque *and* transparent surfaces, keeping only water's running, "without them its reflections hold earlier frames' bytes". Glass is the same case: its screen-space march rarely resolves what it looks at. With the program left out, a window's unresolved rays have no fill at all — no sky (the skip), and no estimate either (`ambient(Role::Miss)` never runs; the skip returns before it) — so the reflection target holds earlier frames' bytes: flickering rectangular red/green/blue/purple blocks, #2440's screenshots. ## Why it only appeared between f9dfb76 and 829188e9 The skip has been in the tree since e2d7854e, which f9dfb76 already contains. But its surface-layer lookup only resolves the miss program's first root constant since the root bindings of #1204 changed the slots — on f9dfb76 the lookup failed, every dispatch ran the program, and glass was given the sky. #2440's own logs confirm it: the f9dfb76 session has no "miss program left out" line (the program ran); on 829188e9 it fires in every stock run. Their run matrix agrees: the three runs where the line fired show the blocks, the three `VICTORY_RAYMISS_KEEP=1` runs (line absent) show clean windows. `VICTORY_RAYMISS_KEEP=1` stays the escape hatch for everything, as before. ## Testing - New `miss_program_kept_tests::only_opaque_is_left_out`: opaque left out (the white-grain fix), alpha and water kept, an unknown layer runs the program. - `cargo test -p victory-gpu --lib`: 915 passed, one failure (`a_change_is_saved_at_once`) is the known parallel-run flake class, 2/2 green in isolation. Fixes #2440 🤖 Generated with [Claude Code](https://claude.com/claude-code)
unueberlegt commented 2026-11-29 14:03:31 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by unueberlegt on 2026-11-29T14:03:31Z.


Closing this: #2464 built exactly this change (a local build that runs the alpha layer's program and leaves out only MISS_OPAQUE) and glass stays noisy there — the layer constants do not split glass from the floors, since one dispatch of the miss program fills the whole half-size target with sky before CS_ResolveScreenSpace writes over it. I have corrected my comment on #2440 accordingly. The direction worth taking is #2464's own (its section 1): give the dispatch's output MISS_LIGHT zero or the stand-in estimate instead of leaving the dispatch out, so the texels the screen-space resolve does not cover hold "no reflection" instead of earlier frames' bytes. The opaque skip that fixed the floors stays as it is.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7257006374 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/2534#issuecomment-7257006374). Originally posted by [unueberlegt](https://github.com/unueberlegt) on 2026-11-29T14:03:31Z. --- Closing this: #2464 built exactly this change (a local build that runs the alpha layer's program and leaves out only MISS_OPAQUE) and glass stays noisy there — the layer constants do not split glass from the floors, since one dispatch of the miss program fills the whole half-size target with sky before CS_ResolveScreenSpace writes over it. I have corrected my comment on #2440 accordingly. The direction worth taking is #2464's own (its section 1): give the dispatch's output MISS_LIGHT zero or the stand-in estimate instead of leaving the dispatch out, so the texels the screen-space resolve does not cover hold "no reflection" instead of earlier frames' bytes. The opaque skip that fixed the floors stays as it is.

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
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.

Reference
trustno1-coder/VIctory-NVIDIA!2534
No description provided.