feat(menu): the Game frame rate cap, Descriptor reuse and Sampler cache apply in play #7

Merged
HumanBean merged 1 commit from HumanBean/Longshot:feat/live-settings into main 2026-11-12 22:23:47 +00:00
Owner

The three rows took a restart only because their values were read once at the start.

  • Game frame rate cap: host/nn_vi.c reads the row at each present (HOS_OPT_FPS_CAP, 53, through the
    renderer's existing option callback; no MkwVkHost/MkwVkRenderer change), the vsync thread re-reads
    its period each tick, and a cap brought down gives the game back its own limiter (+0xfc), its rate
    (+0x2c8) and its step (hos_frame_seconds_bits). The FPS counter's line follows the row. HOS_FPS_MAX
    still holds the cap for a run.
  • Descriptor reuse and Sampler cache: the menu tells vk_draw.cpp the rows at load and on each change
    (menu_debug_rows). A draw keeps descriptors only from a build made with the same setting, so turning
    reuse on never trusts a build that recorded no slot versions. RX_VK_DESC_REUSE and
    RX_VK_SAMPLER_CACHE still hold them for a run.

Checks: tests/test_frame_rate_cap_step.py gains the cap changed in play (up, down, Uncapped, back to
60, and with HOS_FPS_STEP=0); tests/test_menu_env_on.py the Debug rows changed in play.


Moved from NotRexed/Hookshot#2900 (closed when the GitHub account was suspended).

The three rows took a restart only because their values were read once at the start. - Game frame rate cap: host/nn_vi.c reads the row at each present (HOS_OPT_FPS_CAP, 53, through the renderer's existing option callback; no MkwVkHost/MkwVkRenderer change), the vsync thread re-reads its period each tick, and a cap brought down gives the game back its own limiter (+0xfc), its rate (+0x2c8) and its step (hos_frame_seconds_bits). The FPS counter's line follows the row. HOS_FPS_MAX still holds the cap for a run. - Descriptor reuse and Sampler cache: the menu tells vk_draw.cpp the rows at load and on each change (menu_debug_rows). A draw keeps descriptors only from a build made with the same setting, so turning reuse on never trusts a build that recorded no slot versions. RX_VK_DESC_REUSE and RX_VK_SAMPLER_CACHE still hold them for a run. Checks: tests/test_frame_rate_cap_step.py gains the cap changed in play (up, down, Uncapped, back to 60, and with HOS_FPS_STEP=0); tests/test_menu_env_on.py the Debug rows changed in play. --- Moved from NotRexed/Hookshot#2900 (closed when the GitHub account was suspended).
The three rows took a restart only because their values were read once at the start.

- Game frame rate cap: host/nn_vi.c reads the row at each present (HOS_OPT_FPS_CAP, 53, through the
  renderer's existing option callback; no MkwVkHost/MkwVkRenderer change), the vsync thread re-reads
  its period each tick, and a cap brought down gives the game back its own limiter (+0xfc), its rate
  (+0x2c8) and its step (hos_frame_seconds_bits). The FPS counter's line follows the row. HOS_FPS_MAX
  still holds the cap for a run.
- Descriptor reuse and Sampler cache: the menu tells vk_draw.cpp the rows at load and on each change
  (menu_debug_rows). A draw keeps descriptors only from a build made with the same setting, so turning
  reuse on never trusts a build that recorded no slot versions. RX_VK_DESC_REUSE and
  RX_VK_SAMPLER_CACHE still hold them for a run.

Checks: tests/test_frame_rate_cap_step.py gains the cap changed in play (up, down, Uncapped, back to
60, and with HOS_FPS_STEP=0); tests/test_menu_env_on.py the Debug rows changed in play.
HumanBean force-pushed feat/live-settings from e523c93156 to 992a242002 2026-11-12 22:21:35 +00:00 Compare
HumanBean deleted branch feat/live-settings 2026-11-12 22:23:47 +00:00
Sign in to join this conversation.
No description provided.