RT on: the indirect-light stand-in band (VICTORY_AMBIENT_RT) is on by default and darkens shaded surfaces #61

Open
opened 2026-12-01 09:23:06 +00:00 by github-bot · 0 comments
Owner

@⁠LOCKhart07 on GitHub · 2026-12-01 09:18 UTC · original

Summary

With ray tracing on (VICTORY_BVH_BUILDER=1), the indirect-light stand-in in crates/victory-gpu/src/ambient.rs is on by default: rt_band() falls back to "0.7,1.5" whenever VICTORY_BVH_BUILDER=1, so ambient::on() is true and every stand-in pass runs on top of the title's own traced light. On current main with the hardware node test, this visibly darkens surfaces lit only by indirect light. Overhead road signs facing away from the sun render black; with VICTORY_AMBIENT_RT=0 they render dark green with readable text, the same as with RT off. Areas under bridges look too dark too (seen in play, not A/B'd).

What runs with RT on (from the log)

All of these log a stand-in for the indirect light once in a normal RT-on run:

  • Resolve: the title's diffuse resolve is clamped to 0.7–1.5× a screen-space estimate (×0.8 level, ×crease shade).
  • Reflected, ReflectedIn (CS_UpdateHistory, CS_TemporalResolve2_Opaque, CS_TemporalResolve1_Alpha) and ReflectedAlpha: hold / hold_f write c / (1 + luma(c) / cap) with cap = 1.0 × mean ambient luma, so reflections are always darkened (halved at the mean, more above it). They also zero bright low-saturation texels and anything is_garbage_probe flags (green- or magenta-dominant).
  • Air: in-scatter capped at 1.5× the light around.

The doc comment on Band says why it exists: "The title's traced light flickers and goes black indoors while the structures its rays walk are partly wrong". That was true for the software node test. With the hardware node test (90338ca) and committed spans placed whole, our 8-minute RT-on benches log almost no "pages that had no copy" (~40 one-page lines), and the title's own light looks right without the band.

A/B (same build, same save, same scripted camera, 8 min each)

RX 9070 XT, Fedora, kernel 7.3, 2560x1440, main 37bb30f + open PRs #43/#44/#45/#47, hardware node test on, RT on.

default (band 0.7,1.5 on) VICTORY_AMBIENT_RT=0
shaded overhead sign panels black, text unreadable dark green, text readable (matches RT off)
garbage colours / black patches / flicker none seen none seen
errors, device lost 0 0
world fps median (8–10k draws) 36.0 35.0 (more traffic in that run)

Other forks

The forks I checked never run this stand-in with ray tracing, or only on request:

  • Whiplash-AMD/NVIDIA, ReVIctory, Foxhound: on() is ... && !builder_runs(). Whiplash's docs/fork-ray-tracing.md says "It is off while the builder runs".
  • VIctory-RTX, VIctyx, VIctory-RDNA: the same band, but opt-in. VICTORY_AMBIENT_RT unset means off, and the doc comment here still says "unset: off".

Suggestion

Make the band opt-in again (drop the VICTORY_BVH_BUILDER=1 fallback in rt_band()), or at least default it off when the hardware node test is active. Anyone still on the software node test who sees black rooms can set VICTORY_AMBIENT_RT=0.7,1.5.

No game files, screenshots or captures included.

**@⁠LOCKhart07** on GitHub · 2026-12-01 09:18 UTC · [original](https://github.com/lobomfz/VIctory-xmem/issues/61) ## Summary With ray tracing on (`VICTORY_BVH_BUILDER=1`), the indirect-light stand-in in `crates/victory-gpu/src/ambient.rs` is **on by default**: `rt_band()` falls back to `"0.7,1.5"` whenever `VICTORY_BVH_BUILDER=1`, so `ambient::on()` is true and every stand-in pass runs on top of the title's own traced light. On current `main` with the hardware node test, this visibly darkens surfaces lit only by indirect light. Overhead road signs facing away from the sun render **black**; with `VICTORY_AMBIENT_RT=0` they render dark green with readable text, the same as with RT off. Areas under bridges look too dark too (seen in play, not A/B'd). ## What runs with RT on (from the log) All of these log `a stand-in for the indirect light` once in a normal RT-on run: - `Resolve`: the title's diffuse resolve is clamped to 0.7–1.5× a screen-space estimate (×0.8 level, ×crease shade). - `Reflected`, `ReflectedIn` (`CS_UpdateHistory`, `CS_TemporalResolve2_Opaque`, `CS_TemporalResolve1_Alpha`) and `ReflectedAlpha`: `hold` / `hold_f` write `c / (1 + luma(c) / cap)` with `cap = 1.0 × mean ambient luma`, so reflections are always darkened (halved at the mean, more above it). They also zero bright low-saturation texels and anything `is_garbage_probe` flags (green- or magenta-dominant). - `Air`: in-scatter capped at 1.5× the light around. The doc comment on `Band` says why it exists: "The title's traced light flickers and goes black indoors while the structures its rays walk are partly wrong". That was true for the software node test. With the hardware node test (90338ca) and committed spans placed whole, our 8-minute RT-on benches log almost no "pages that had no copy" (~40 one-page lines), and the title's own light looks right without the band. ## A/B (same build, same save, same scripted camera, 8 min each) RX 9070 XT, Fedora, kernel 7.3, 2560x1440, `main` 37bb30f + open PRs #43/#44/#45/#47, hardware node test on, RT on. | | default (band 0.7,1.5 on) | `VICTORY_AMBIENT_RT=0` | |---|---|---| | shaded overhead sign panels | black, text unreadable | dark green, text readable (matches RT off) | | garbage colours / black patches / flicker | none seen | none seen | | errors, device lost | 0 | 0 | | world fps median (8–10k draws) | 36.0 | 35.0 (more traffic in that run) | ## Other forks The forks I checked never run this stand-in with ray tracing, or only on request: - Whiplash-AMD/NVIDIA, ReVIctory, Foxhound: `on()` is `... && !builder_runs()`. Whiplash's `docs/fork-ray-tracing.md` says "It is off while the builder runs". - VIctory-RTX, VIctyx, VIctory-RDNA: the same band, but opt-in. `VICTORY_AMBIENT_RT` unset means off, and the doc comment here still says "unset: off". ## Suggestion Make the band opt-in again (drop the `VICTORY_BVH_BUILDER=1` fallback in `rt_band()`), or at least default it off when the hardware node test is active. Anyone still on the software node test who sees black rooms can set `VICTORY_AMBIENT_RT=0.7,1.5`. No game files, screenshots or captures included.
github-bot locked as GitHub sync and limited conversation to collaborators 2026-12-01 09:23:06 +00:00
This discussion has been locked. Commenting is limited to contributors.
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.

Dependencies

No dependencies set

Reference
github/lobomfz--VIctory-xmem#61
No description provided.