fix(ambient): add opt-in chromatic probe-garbage scrub (VICTORY_AMBIENT_CHROMA_SCRUB=1) #280
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/280"
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?
Imported from TaynanGT/Vice-Tay. Originally posted by Vladimir-Human on 2026-11-27T13:32:38Z.
Summary
Split out from #255 per review feedback so chromatic probe-garbage filtering can be evaluated independently and stays strictly opt-in (OFF by default).
When
VICTORY_AMBIENT_CHROMA_SCRUB=1is set alongsideVICTORY_AMBIENT,ambient.rs'sraisepass drops three additional chromatic probe-garbage signatures left by unbuilt/stale screen probes (related to #168):was.b > 2.5 * was.g && was.b > was.r && was.b > 0.02, ported fromVIctory-NVIDIA826ba15) which otherwise bypass the luminance cap (LUMA.b = 0.0722).was.g > 2.5 * max(was.r, was.b) && was.g > 0.02).was.r < 0.35 * min(was.g, was.b) && max(was.g, was.b) > 0.02).When
VICTORY_AMBIENT_CHROMA_SCRUBis unset or not1(the default), bit 1 of the existingproberoot constant (words[11]) is0, preserving exact upstreamambient.rsbehavior with zero root-signature or PSO changes (existing lightprobe stats check(probe & 1u) != 0).Changed Files
crates/victory-gpu/src/ambient.rs: opt-inVICTORY_AMBIENT_CHROMA_SCRUB=1switch, guarded chroma-spike checks inRAISE, unit test (chroma_scrub_is_opt_in), and a 12-tone D3D12 hardware + WARP test (raise_opt_in_chroma_scrub_filters_spikes_and_preserves_scene_tones_on_hardware_and_warp).crates/victory-gpu/src/indirect.rs:#[cfg(test)]pub(crate)visibility onWarpHarness::onfor test reuse.Verification
Verified on local D3D12 hardware (NVIDIA GeForce RTX 4070 SUPER) and WARP (
VICTORY_D3D12_DEBUG=1,--test-threads=1,0D3D12 debug layer errors):cargo clippy -p victory-gpu --all-targets --locked -- -D warnings(default &--features diagnostics): 0 warnings.cargo test -p victory-gpu --locked ambient::tests -- --test-threads=1(default &--features diagnostics): 9/9 passed on both hardware and WARP, confirming in bothscrub_on=false(default) andscrub_on=true(VICTORY_AMBIENT_CHROMA_SCRUB=1):cargo run -p xtask --locked -- policy&cargo test -p xtask --locked: 11/11 passed.Imported from TaynanGT/Vice-Tay. Originally posted by TaynanGT on 2026-11-27T13:37:42Z.
@Vladimir-Human This is the right scope for a separate image test. Use the same foliage move with the flag off and on, plus a shot containing deliberate violet or cyan light. The 12-tone test gives us a synthetic reference for what the filter is supposed to preserve.
Imported from TaynanGT/Vice-Tay. Originally posted by TaynanGT on 2026-11-30T17:13:29Z.
mainhas moved to a new line of the code and everything is now named Vice-Tay, so this PR no longer applies as it is (details in #468). If you'd like this change in, please rebuild it on the currentmainand open a new PR; I'll review it there.Pull request closed