Loader: opt-in switches for the title's LOD, small-object cull, vehicle LOD and shadow settings #3817
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/3817"
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 Marvisak/VIctory. Originally posted by lucaseddd on 2026-11-29T03:11:05Z.
Adds opt-in switches for five of the title's own engine graphics settings, patched in the loaded image before any title code runs:
VICTORY_LOD_SCALE(world LOD distance);VICTORY_SMALL_CULL(small-object cull threshold);VICTORY_VEHICLE_LOD_BIAS;VICTORY_LOW_SHADOWS(shadow-atlas tier);VICTORY_LOW_VOLUMETRIC.Every switch is off unless set, so default behaviour is unchanged.
The code is ToLIManl/VIctory-Hydra's
crates/victory-loader/src/engine.rsat85e7e07(GPL-3.0), credited in the module header, with its settings-menu status hooks removed.site_patch.rsis its byte-verified, all-or-nothing patch core. Every site is compared byte for byte against title 1.0.2.1 before writing; another build is left alone and logged asDiffers.Why
On low-end cards the frame is bound by host preparation, not pixels: a 720p output does not raise fps (#3505, #3810). These settings cut the work per frame: fewer draws, so less preparation. They use the title's own LOD and culling tables, not a render-scale hack.
Measured
RTX 3060 Laptop 6 GB (D3D12 budget about 5.2 GB), Ryzen 7 5700X, game package on a 5400 rpm HDD, Series S, 1080p output (render 720p, title upscaler). VI-BR-PORT-based runtime, warm caches. Full report: lucaseddd/victory-rea build round 1; context in #3816.
LOD_SCALE=0.35,SMALL_CULL=2.0,LOW_SHADOWS=1280,LOW_VOLUMETRIC=1These are single sessions, not paired A/B runs: read them as the size of the effect, not a precise figure.
A later session with
LOD_SCALE=0.35,SMALL_CULL=2.5,VEHICLE_LOD_BIAS=0.5,LOW_SHADOWS=1024and without the volumetric setting had a correct image (hair, floors, walls, lights and shadows checked by eye), with a world median of 10.2 fps and p10 of 9.3 fps. That session also carried two unrelated runtime changes, so it confirms the image rather than isolating the fps.Known issue, stated plainly: with
VICTORY_LOW_VOLUMETRIC=1(and 1,280 px shadows), floors and walls went black indoors and lamps blew out on that runtime. The setting shrinks the reflection cubemap from 64x64x6 to 32x32x6, and the shaders there did not cope. The docs say to keep it off unless the shader side handles the smaller cubemap. The other four switches were clean.Tests
cargo test -p victory-loader --lib -- engine site_patch: 6 passed. They cover the sites' geometry, the replacements, the parsing, and thatapply_setis all-or-nothing on a mismatch.golden_title_exe_bytes_if_presentpassed withVICTORY_TITLE_EXEpointing at a real 1.0.2.1 executable: every site's expected bytes match. Without the variable it skips, asdocs/asset-policy.mdasks.cargo build --release -p victoryandcargo xtask policy(193 files ok) pass, andcargo fmt --checkis clean for the files this PR touches.Doneon 1.0.2.1.Imported from Marvisak/VIctory. Originally posted by lucaseddd on 2026-11-29T03:32:50Z.
The one failure in the CI run is
victory-gpu'sdescriptor::host::tests::views_bound_while_another_slot_gets_its_texture_do_not_wait("both made",descriptor/host.rs:2011). This PR does not touchvictory-gpu: it only adds twovictory-loadermodules and four lines inapps/victory/src/run.rs.The same test on this branch passed 30 out of 30 runs locally (Windows, MSVC,
--release). It looks timing-dependent under a loaded parallel test run, so I'd ask for a re-run of the failed job. The CI's earlier steps (formatting, clippy and build) passed, and so did the PR's own tests.View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.