Frame clock: VICTORY_FRAME_INTERVAL_DRAWS keeps the title's own 30 for the opening animation, videos and menus #2077
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/2077"
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 trustno1-coder/VIctory-NVIDIA. Originally posted by borntofrag34 on 2026-11-29T09:09:39Z.
What it changes
With
VICTORY_FRAME_INTERVAL_MS(or_US) set, our frame clock ticks at that interval on every frame, including the opening animation and the videos. Those are made for the title's own 30 fps. Ticked at 60, frames come twice:VICTORY_FRAME_INTERVAL_DRAWS=<n>(off by default) uses the asked interval only after a frame that ranndraws or more. Otherwise it uses the title's own 33.3 ms: from the start, and again after 30 frames in a row with fewer draws. The 30-frame margin is there because a frame of the world can count few draws when its lists are translated into the next frame. Without that margin the clock changed 183 times in 100 s.500is the same lineworld_frame/VICTORY_CAPTURE_WORLDalready draw between the world and what comes before it. When it is unset, nothing changes.frame.rs: the switch,frame_drew()and a pureby_draws()with a unit test. An asked interval longer than 33.3 ms is kept, and uncapped (0or_US=1000) still gives 30 for the videos.lib.rs:world_frame()hands each frame's draw count toframe::frame_drew().docs/README-foxhound.md: one row in the switch table.How it was tested
VICTORY_FRAME_INTERVAL_MS=16.667, run 98): the duplicates above, found by comparing captured frames one by one.VICTORY_FRAME_INTERVAL_DRAWS=500, run 100): 98 new frames out of 100 in the opening and none shown twice. The world's frames were the same as before. That branch's launcher has had it on since 27 Nov.main829188e9builds forx86_64-pc-windows-msvc.clippy --no-deps -p victory-gpureports nothing in the touched lines (mainalready has unrelated clippy errors elsewhere, see #2019).cargo test -p victory-gpu --lib -- frame:: world_tests: 4 passed, run under Wine. I have not run this port in the game on this tree. The frame clock and the loader's coupled rate patch here differ from the branch I measured on, so a check by someone on Windows/NVIDIA with-Fps 60is welcome.cargo testpassed for the crates it touches: yes (the tests above)Checked for overlap
frame.rsor on frame pacing of videos.🤖 Generated with Claude Code