github valentderah/totk-pc-recomp v0.4.1

one hour ago

To update, run the new installer on your existing install folder. It keeps your game files, saves and totk.ini, and rebuilds totk.exe and the shaders.

Warning

I have not tested the Linux build myself. DLSS is tested by the community only: I don't have the hardware for it.

Note

If something got worse. Change one at a time (the settings menu, F1, or totk.ini), restart the game and check the same place. Then open an issue with logs/totk.log attached and say which switch helped.

  • FPS falls after 5-10 minutes of play and a restart brings it back (#1174). Add addr_report = 0 under [diagnostics] in totk.ini.
  • Graphics artifacts, wrong textures or colours: memx = 0.
  • AMD on Windows, new holes or noisy edges on foliage, fences or hair: start the game with the environment variable TOTK_DEMOTE=0.
  • HDR colours look wrong: hdr_hue = 0.
  • Objects, Recall or Ultrahand behave oddly: optref_guard = 0, ability_guard = 0 or report_guard = 0. Each turns off a crash guard, so the crash it stops can come back.
Experimental: the Linux PGO build and settings that are off by default.

Experimental Linux build with PGO. TotK-Setup-0.4.1-x86_64-pgo.AppImage is built with profile-guided optimisation, as the Windows installer is. On Windows PGO gives 6-12% more FPS, and the Linux build should gain about as much, but nobody has measured it on Linux yet. If it misbehaves, use TotK-Setup-0.4.1-x86_64.AppImage. Please report your FPS with both builds in an issue.

Settings. These switches can give more FPS on some PCs and do nothing or harm on others. Set them in the Advanced tab of the settings menu (F1) or in totk.ini under [performance]; they take effect at the next start unless noted. Try one at a time and compare the FPS at the same place. If one breaks something, set it back to its default and tell us in an issue with logs/totk.log attached.

  • replay_workers = 4: record the GPU commands on several threads. Each large submission is recorded in chunks on this many threads (0 to 16). In a town at 4K on an RTX 5070 the replay went from 8.2 to 4.5 ms a frame (71 to 79 fps); more than 4 threads add little. Needs 8 or more logical processors. No gain where the game's own threads limit the frame (a Ryzen 7900X at 1080p). This release fixes the freeze and the chunk_record crash it caused (#1104).
  • sync_ahead = 1 with shadow = 1: one frame ahead of the GPU. The game builds the next frame while the GPU still draws the previous one. On Great Sky Island (Linux, RX 9070 XT) this took about 73 to 100 fps. Costs one more frame of input delay, frame times vary more, and GPU results the game reads back (occlusion queries) can be a frame old, so an object can pop in a frame late. On native Windows it needs shadow = 1 (on by default on Linux and Wine): a copy of the game's GPU-visible memory, about 0.2 ms a frame and 1.1 GB more memory. Helps most where the game waits for the GPU. Works on 1.2.1 and 1.4.3.
  • replay_async = 1: the GPU replay on its own thread. Runs the replay at most one frame behind the game. Helped a GTX 1650 in the Depths, where the game waits for the GPU; on a GTX 1660 Ti at the 60 fps limit it made motion uneven (#659). Up to one frame more input delay.
  • bind_inc = 1: rebuild only what changed between draws (#381). The draw thread rebuilds only the bindings, shaders and pipeline state whose inputs changed since the previous draw: about 3% less time on that thread in a town (Ryzen 7900X limited to 4 cores). One GTX 1050 Ti lost the GPU ("device lost", -4) with it at one place in the world, and the cause is not found yet. If you get -4 with it, please attach logs/totk.log.
  • frame_queue = 1: a frame waits in a queue for its display time. The game starts the next frame while the previous one waits, so a frame that runs long still makes its turn: far fewer dropped frames at the fps limit, for up to one frame more input delay. Takes effect at once.

Memory and crashes

  • Fix random crash after minutes to hours of play (#1005, #1137, #1145). A broken reference the game left in an object's data now counts as empty instead of closing the game. Recall and Ultrahand skip a target whose memory the game already freed, for that frame only. A crash in the model scene while using Ultrahand or aiming is guarded too. Each guard has its own switch in totk.ini (optref_guard, ability_guard, report_guard, all on by default). No cost.
  • Less freeze or crash after a few minutes with replay workers on (#1104). With replay_workers above 0 the picture could freeze for good, or the game crashed in chunk_record: a search in the table of rendered images ran past its entries and overwrote the replay's state. With replay_workers = 0 (the default) the fix also tells effects rendered every frame from one-shot ones correctly. No cost.
  • More detail in "device lost" (-4) crash logs. When the GPU stops with error -4, totk.log now also lists the last descriptor pool events before it, and a pool used by two submissions at once is logged the moment it happens. If the game closes with -4, please attach logs/totk.log to your report. No measurable cost.
  • No more crash on a charged spear hit above 60 fps (#1194). On 1.4.3, when the weapon's list of hit records was full, the game read a stale entry before checking whether the list was empty. It now checks first. No cost.

Fixes

  • DLSS: a preset change reaches every scene size. With dynamic resolution the game renders at up to five sizes; a preset change in the menu rebuilt only three, and the other two kept the old model until they were evicted.
  • Mods: a sound mod with a file named for another game version plays again (#1101). The port skipped mod files named with .Product.<number>. that the game's own files lack, but the game asks for such names (1.4.3 opens Pack_MasterSword.Product.110.bars.zs). They are now served under their own names; another version's resource size table still only lends its entries.
  • DLSS upscaling on 1.2.1 shows the whole picture again (#1106). With dlss = quality, balanced, performance or ultra_performance on 1.2.1 the 3D view showed only its top-left part stretched over the screen. The game's own 1.2.1 upscaler is now skipped after DLSS, as the FXAA draw already is on 1.4.3. 1.4.3 and runs without DLSS are unchanged.
  • The setup says why it cannot write totk.exe (#1122). When an antivirus or a running game holds totk.exe, the setup names both causes and tells you to close the game, exclude the setup's and the install folder in the antivirus and run it again, instead of the bare "Compiling totk.exe failed".
  • HDR: fire and bright coloured lights no longer glow neon (#552). Bright colours in HDR now take their hue and their fade towards white from the game's SDR picture (RenoDX's TotK colour reconstruction), highlights roll off smoothly to your display's peak, and shadows match an SDR monitor (gamma 2.2), so the darkest areas are a little deeper. Settings > Screen > Highlight hue correction sets the strength: 0 turns it off, the new default 70 matches RenoDX. SDR is unchanged.
  • DLSS and DLAA: no more flicker, flashing mist or wrong frames in menus (#1161, #1162, #1163, #1184). With dlaa = 1 the picture no longer flickers at some views (Lookout Landing), distant mist no longer flashes for single frames, the inventory no longer shows a weapon icon stretched over the screen, and closing the quick weapon menu no longer shows a dark, blurred frame. DLSS now waits for the real scene and its bloom instead of taking an icon, a half-size effect or a sky lookup for them. Without DLSS nothing changes. No cost.
  • No black strip by the quick weapon menu with replay workers on (#1164). With replay_workers above 0, the first opening of the quick weapon menu after a load could show a dark strip right of the last slot for a frame. With replay_workers = 0 (the default) nothing changes. No cost.
  • shadow = 1 in totk.ini no longer logs "unknown key" (#1165). The setting always worked; the log line suggested otherwise. It is now listed in totk.ini.example.

Controls

  • Gyro aim no longer drifts on its own (#1197). Some controllers report a small turn while lying still. Calibrate gyro on the Controls tab, under Motion controls, measures that offset in about a second with the controller flat on a table and removes it. Each controller keeps its own calibration across restarts; if it moved during the measurement, the game asks you to try again. Without a calibration nothing changes.
  • Keyboard and mouse prompts follow your key bindings (#1098, #147). With the PC prompts, the prompts in text (menu guides such as Sort, the dialogue log) show T for Y instead of the left mouse button. The setup draws the PC prompts from the bind_ lines of totk.ini: after changing bindings on the Controls tab, run the setup again.
  • Left click on the map (#1096, #62). Left click on the map on the Controls tab (map_click = 1) makes the left mouse button press A at the cursor on the Purah Pad's map instead of its binding (Y by default). Off by default; changes while the game runs.
  • Mouse clicks in dialogue (#1097, #62). Clicks in dialogue on the Controls tab (dialogue_click = 1): a left click continues the text (or shows the rest of the line at once), a right click presses A, instead of opening the dialogue log. Off by default; changes while the game runs.
  • The mouse wheel in menus, the D-pad strips and the camera (#1092, #356, #62). The wheel scrolls menus one item per notch, steps the weapon, shield and material strips while the D-pad holds them open, and zooms the Purah Pad's camera. After the wheel or keys moved the focus, a resting mouse no longer pulls it back until the pointer moves a little.
  • Game pointer (#1118). Game pointer on the Controls tab (pointer_image = 1) replaces the system arrow with a gold arrowhead sized for your screen scale while the cursor is free (game menus, settings menu, after Esc). Off by default; changes while the game runs.
  • Gameplay tweaks for keyboard and mouse (#1136). Gameplay tweaks on the Controls tab (gameplay_tweaks_enabled = 1): the wheel turns an object Ultrahand holds (C + wheel: the other axis, right button + wheel: nearer or farther), opens and steps the weapon bar in free roam (E equips, right click or B cancels), steps the D-pad strips (A and D work there too) and zooms the map smoothly. Each part has its own switch and speed. Off by default; changes while the game runs.
  • The DualSense touchpad click is a bindable button (#482). On the Controls tab the DualSense or DualShock 4 touchpad click (pad:touchpad) can be bound to any Switch button. Unbound by default. A pad through Steam Input shows up as an Xbox pad and has no touchpad.

Performance

  • No 2 ms waits for the command recorder (#1174). The thread that records Vulkan commands could miss its wake-up and sleep out a 2 ms timeout while work waited, holding up the present, uploads and readbacks. A log from #1174 on an RX 9070 XT showed such waits of 1.6 to 3.4 ms late in a session, against 0.04 ms at its start. No measurable cost.
  • NVIDIA Reflex low latency (#638, #913). Settings > Screen > NVIDIA Reflex Low Latency (reflex = on or boost) cuts the delay between your input and the picture on NVIDIA GPUs; boost also keeps the GPU clocks high where the CPU limits the frame. Off by default, takes effect at the next start, no effect on other GPUs.
  • Less CPU time for drawing (#381). The thread that turns the game's draw commands into Vulkan compares and copies each draw's state inline instead of calling the C library: about 5% less time on that thread in Lookout Landing and Kakariko (Ryzen 7900X limited to 4 cores). Helps most where that thread limits the frame rate. memx = 0 in totk.ini turns it off. No cost.
  • Less CPU time for drawing, part 2, off by default (#381). The same thread can rebuild only what changed since the previous draw. It is off for now on Windows and Linux; see bind_inc in the Experimental section above.
  • Less overhead in the game's own code (#381). Game functions no longer test a debug hook on entry (only the one the resolution settings watch does), and calls into the port are counted only in diagnostic runs. No cost.
  • Faster game code. Game functions keep their most used vector registers in CPU registers instead of memory: 4-6% less CPU time for the game's code in a town (Ryzen 7900X).
  • Leaner floating-point checks (#381). The checks that keep floating-point results exactly as on the Switch take 8% fewer instructions in the hottest functions and no longer touch extra stack memory on every call. Results stay identical bit for bit (checked on billions of operations in play). The gain is a percent or two of the game's CPU time. No cost.

Overall: about as fast as 0.4.0 (Ryzen 9 7900X, RX 9070, 1440p). Lighter scenes gain a few percent, and fights no longer hitch for 40 ms now and then.

Graphics

  • No more light halo round objects against clouds and fog on AMD (#164, #1203). On Radeon cards under Windows, ropes, rocks and characters against clouds, fog or mist had a light blocky fringe round their outline. Shaders now handle a discarded pixel as the Switch does, so the fog next to it is drawn in full. The first start after updating prepares the changed shaders once (about 20 s on a fast CPU). No measurable cost; NVIDIA, Intel and Linux are unchanged.
  • Contact shadows no longer darken rock faces in the shade (#1200). With contact shadows on (Settings > Screen, contact_shadows above 0), faces turned away from the sun (canyon walls in haze, undersides of overhangs) kept dark dithered bands; they now keep the game's soft shade, and fewer dark strokes cross the grass. Shadows at feet, under stones and in sunlit grass stay. Off by default; no measurable cost.
  • Grass range (#1087, #1085). Settings > Screen > Grass range (grass_range, 50 to 400 %) sets how far around the camera grass grows: 200 or 400 reach 125 or 250 m instead of the game's 62.5 m, 50 draws less. The grass textures grow with it to keep the detail: about 27 MiB more memory at 200 %, 137 MiB at 400 %. 100 is the game's own; read at start.
  • Game 1.1.0 gets the frame-rate, camera and shadow patches (#1002). On 1.1.0 the map cursor and the vertical Ultrahand and gyro aim keep their speed at 60 fps and above, the equipment switch cooldown no longer sticks, the field of view and ultrawide aspect ratio work, and the shadow map size, shadow range and texture pool offset settings apply, as on 1.2.1 and 1.4.3. 1.2.1 and 1.4.3 are unchanged.
  • Steady detail under load (#322). Settings > Screen > Steady detail under load (lod_steady = 1) stops the game from lowering model and texture detail when the frame rate drops, like the emulator mod Disable LOD Quality Reduction. Off by default, read at start; leave it off on weak PCs, where that drop holds the frame rate. Games 1.2.1 and 1.4.3.

Menu and overlay

  • Code cheat changes rebuild much faster (#996). After a code cheat change the setup lifts again only the parts of the game code it touches: about 4 seconds instead of one to two minutes on a fast PC, more saved on slower ones. TOTK_LIFT_CACHE=0 lifts everything as before. No cost in game.
  • The setup prepares the screen layouts much faster and smaller. It used to write the HUD layout for every prompt style at all 15 screen sizes (64 folders, about 6.5 minutes and 370 MB). Now it writes the 16:9 folders plus the shapes of your connected monitors for your chosen prompts only: nothing extra on 16:9, about 25 seconds on 21:9. After a monitor change, the game-resolution row in the settings marks a size without its layout and can prepare it in the background, for the next start.
  • Linux: "Rebuild the game now" builds the code cheats in again (#560, #403). On the AppImage the button restarted the game with its old code, so code cheats stayed greyed out and later starts skipped the rebuild too. The game now starts the setup AppImage itself, and a rebuild that could not start is tried again at the next start. Run this release's setup once on your install folder, and keep the AppImage where it is: the rebuild starts it from there. Windows is unchanged.
  • Linux: Chinese, Japanese and Korean show in the settings menu under Flatpak (#1115). The menu looked for its CJK font in five fixed places and showed ? when none existed, as in a Flatpak sandbox. It now asks fontconfig first. menu_font_fontconfig = 0 keeps the old lookup. Windows is unchanged.
  • Separate music, effects and voice volumes (#722, #1146). Settings > Sound has Music, SFX and Voice sliders (volume_music, volume_sfx, volume_voice, 0 to 100, on top of Volume): turn the music down and keep combat sounds and voices. Voice covers character lines and the calls of creatures and Link. A slider moved during play reaches a playing track at its next stream read; a few quiet sounds the port cannot place follow SFX. At the defaults (all 100) nothing changes and nothing extra runs.
  • Choose the audio output device (#1014). Settings > Sound > Output device (audio_device) lists your playback devices by name; a change moves the sound to it at once, while the game plays. If the chosen device is unplugged, the sound goes to the system default and comes back within a second of plugging it in again. System default (the default) works as before. No cost.

Thanks

Thanks to RxEmam for the keyboard and mouse gameplay tweaks and the music, effects and voice volumes, t04dJ14n9 for the DLSS preset fix, STS78721 for NVIDIA Reflex, itaskaev2 for carrying it onto dev and fixing its present IDs, for the mouse wheel in menus, strips and the camera, for grass_range, for the DLSS fix on 1.2.1, for the pointer image switch, for the setup's message about a locked totk.exe, for the shadow key, for the contact shadows on shaded faces and for checking the DLSS fixes on an RTX 4080, Pannenkoekepan for reporting it, ipavlin98 for the replay workers freeze fix, the DLSS and DLAA flicker and menu fixes and the quick menu strip fix, Nehalem95 for reporting it, jcleng for the fontconfig lookup of the menu's CJK font, xellow78-lgtm for the mod file fix, Wesley-CR for the lift cache that makes cheat rebuilds fast, shenjackyuanjie for the 1.1.0 patch sets and the video memory self-test fix, lwj10case for the keyboard prompts that follow the bindings and the mouse clicks on the map and in dialogue, ChildInside for reporting the DLSS picture on 1.2.1, and nyokkard, CrimsonStaff, LuizDavid48, kaimian and visal123-beep for the crash reports behind the optional reference and ability target fixes, Zenrap0518 for the HDR colour reconstruction, ben-page for tracing the Linux cheat rebuild, and DonatelloEsq, undeadsavage94, Zakeau and ptcarino for reporting it, aminenrr for asking for the touchpad button and Chalking for asking for the output device choice, ProSep for the steady detail switch, from theboy181's and sweetmini's emulator mods, project-snail for the charged spear crash fix, palxex for the gyro calibration, codexx-dev for the cloud halo fix on AMD, dnlwzl for reporting it, and 1033929578-tech for the log that showed the recorder's late wake-ups.


This discussion was created from the release v0.4.1.

Don't miss a new totk-pc-recomp release

NewReleases is sending notifications on new releases.