Skip to content

V17 (pre-release): a steady 30 fps on the iPhone

Pre-release
Pre-release

Choose a tag to compare

@cheemu21 cheemu21 released this 08 Nov 19:50

Pre-release: source code only. No IPA and nothing from the game are attached or in the repository. Build your own from your own dump of the game (the v1 dump: base game + update v131072) with the steps in docs/games/kid-with-sword-remake.md, with an env file holding the lines under "Build settings" below.

The Legend of Zelda: Ocarina of Time (Switch 2) as a native iPhone and Mac app, on top of nxnative.

In this build (V17): a steady 30 fps

At 30 fps an iPhone lowers the GPU clock until the work fills most of the frame. On an iPhone 18 Pro at render scale 0.25 the GPU took 12 ms a frame at 60 fps but 29–30 ms at 30, with spikes of 33–38 ms. So most frames missed their refresh (log 60: 195 of 300 over 33.3 ms), and the frame step's catch-up jumps juddered about three times a second.

  • Frame buffering on by default: the CPU and the GPU work at the same time instead of taking turns. The launcher's Frame buffering row starts on.
  • Two frames for the GPU at 30 fps: 66 ms from submission to display instead of 33, so a 34–38 ms frame no longer drops. This adds about 33 ms of input lag, at 30 fps only.
  • No catch-up jumps: a late frame slows the game for a moment, as on a console, instead of a jump in motion on the next frame.
  • The GPU profile and Metal HUD lines from V16 are not baked in.

Since V13

  • Render scale slider (V15-touch2): one slider from 0.25 (marked Potato) to 1.0, default 0.667 (1280×720 handheld), in place of the Resolution preset.
  • Touch controls (V15-touch): the Zelda layout from the A builds: icons, ZL lock, D-pad.
  • LDSM fix (V15): no more white flashes from the game's upscaler networks (upstream PR seedds#1376).
  • Deadline boost off by default (V14), a jump icon on X.
  • V16: a GPU profile build (for measurement only).

Build settings

DM_UPSCALER=metalfx
DM_FPS_HOLD=off
DM_THERMAL_CAP=0
DM_QOS_MAP=1
DM_QOS_EDGES=45,59

Status

  • V17 is not yet tested on the iPhone. The frame-step unit tests pass.
  • At 60 fps the phone holds 60 for about a minute, then iOS lowers the clocks once it warms up (thermal state 1) and it falls to 37–43 fps.
  • Known: magenta or black textures can appear after some area changes.

Not affiliated with Nintendo.