Repository navigation
Add a render-scale ceiling for Ocarina v131072 - #1497
givethesourceplox wants to merge 1 commit into
Conversation
… DM_RENDER_SCALE) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_013SzykpcKm2eZPvPjGPKx1C
…and turns its dynamic resolution off, at the final scale store upstream PR seedds#1497 found (0.99 renders 1920x1080 on the Mac's 1080p output, GPU 42-52 ms at the Kokiri Forest on an M4)
…namic frame step, DM_NDSR=game, present bilinear
…tep (upstream PRs seedds#1497 and seedds#1543) Both stubs are FRAME_STEP of main e0f3ccfaf50065ae4ea01eb5aeb13b1a, so the build's function runs both: real_speed at main+0x6e6cc4 (frame step from the measured frame time) and render_scale at main+0x31d3f48 (DM_RENDER_SCALE caps the game's dynamic-resolution scale). test_oot_real_speed checks the build takes both sites and marks the render-scale capability; game-patches.md regenerated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Aax1HnchwCweUDRNWjhHx9
…tep (upstream PRs seedds#1497 and seedds#1543) Both stubs are FRAME_STEP of main e0f3ccfaf50065ae4ea01eb5aeb13b1a, so the build's function runs both: real_speed at main+0x6e6cc4 (frame step from the measured frame time) and render_scale at main+0x31d3f48 (DM_RENDER_SCALE caps the game's dynamic-resolution scale). test_oot_real_speed checks the build takes both sites and marks the render-scale capability; game-patches.md regenerated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Aax1HnchwCweUDRNWjhHx9 (cherry picked from commit 1e0258b)
…mmits on top of main, without the real-speed and render-scale frame steps (seedds#1543, seedds#1497), which main's own frame step (7d8dcdf) and dynamic-resolution switch (04419bc) replace (this merge keeps the earlier branch history reachable, so the push needs no force) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Aax1HnchwCweUDRNWjhHx9
|
On v131072 the scale store at main+0x31d3f48 runs only in a frame where the dynamic-resolution update answers status 0, a new scale. Its caller tests the status byte at main+0x31d3ee4 ( At a steady frame rate the update never answers 0, and on current main the level stub (7de11da) holds the top level by default. So a stub at the store alone changes nothing until the game comes under load. That is what we saw with the same single-site approach before adding a second stub. #1903 adds that second stub at the status test (once, until the host scale has been applied). It is placed by the view-size update's fingerprint rather than the build ID. It takes the setting as a fraction of the game's own size, as Breath of the Wild and Tears of the Kingdom do, rather than a ceiling. The numbers are in its description. If the ceiling semantics are wanted instead, the status stub is what makes either one apply. |
Upstream pull requests applied in this commit (their authors' work, brought onto this tree with a three-way merge; the description is in each PR): - seedds#1497 by givethesourceplox (open): Add a render-scale ceiling for Ocarina v131072
…nds once to half), seedds#1909 (fragment uniform reads bound to the binding length), seedds#1901 (dispatch_overlap on for Ocarina), seedds#1459 (MetalFX takes agl_ndsr_vr, no-curve variants linear), seedds#1903 (render scale stubs for Ocarina; replaces the seedds#1497 ceiling we carried) Hand-resolved: the mesh draw keeps the task isolation of seedds#1842 and the copy paths our nvn_tex_level_range / DM_SHARPEN; seedds#1497's stub, test and BINDING entry go; the build-keyed rule names the render scale function (main+0x31d3200). Chain e906c7467690. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014eD437mxrMnW2UwLZhpwc7 Upstream pull requests applied in this commit (their authors' work, brought onto this tree with a three-way merge; the description is in each PR): - seedds#1459 by PromethOps (open): DM_UPSCALER=metalfx takes agl's agl_ndsr_vr.pck networks too, and a variant with no curve and no power is drawn as one colour space: Ocarina of Time's upscaler is MetalFX's - seedds#1497 by givethesourceplox (open): Add a render-scale ceiling for Ocarina v131072 - seedds#1842 by ycarogabriel-lgtm (open): Ocarina of Time: opt-in task isolation (DM_NVN_ISOLATE_TASK), the Hi-Z task a5288 in command buffers of its own, a workaround for its GPU hangs on an M1 - seedds#1897 by Know-It-All-Brother (closed): HMMA with an f16 accumulator rounds once per 8 products, as Ampere does (chain change) - seedds#1901 by FifteenPen (open): The game's compute dispatches with no game barrier between them run side by side (profile key dispatch_overlap, on for Ocarina of Time): Kokiri Forest GPU p50 15.63 → 14.76 ms - seedds#1902 by fxd0h (open): HFMA2 rounds once to half, as Ampere does (chain change) - seedds#1903 by FifteenPen (open): Ocarina of Time takes the launcher's Render scale: the 3D views at that fraction of the game's own size, the dynamic resolution held at its top level (Kokiri Forest docked at 0.75: GPU p50 15.77 → 14.31 ms, 60 fps held) - seedds#1909 by oz-rinkliff (open): Bound translated fragment uniform reads to the NVN binding length
Ocarina v131072 now honors the existing host render-scale setting as a ceiling on the scale chosen by the game. For example, a 50% ceiling caps a game-selected 75% scale at 50%, while allowing the game's dynamic resolution to drop below that ceiling. The default 100% setting preserves the game's selected scale.
The game profile checks build ID e0f3ccfaf50065ae4ea01eb5aeb13b1a and the original instruction at main+0x31d3f48 before patching the final scale store. The stub preserves all integer and SIMD registers, the stack pointer, and condition flags. It uses the existing host state and advertises RENDER_SCALE so the current launcher control becomes available. Frame timing and the shader translation path are unchanged; no shader rebuild is needed.
Validation:
An earlier version of the cap was exercised on an M1 Pro through the house-to-forest route. This isolated implementation was verified with the actual rewritten image and ARM64 execution; sustained performance gains, later areas, and iOS remain unmeasured.