Merge upstream dev 25a53e5 into fsr4

Conflicts: runtime/cfg.c keeps dev's FREECAM_* names next to the FSR_* ones; runtime/vk_dlaa.c keeps dev's two
FXAA_FS hashes for translator patch 0017 (#1299) and this branch's FXAA_COPY_FS.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
codexx-devandClaude Opus 5.5 committed 2026-11-21 17:41:04 -03:00
commit c71222fecb
22 files changed
+779 -44

No files matched your search

+2
View File
@@ -122,6 +122,8 @@ static const char *pad_label(int p) {
return menu_text((UiTextId)(UI_PAD_SOUTH + (p - PAD_SOUTH)));
}
const char *binds_pad_label(int pad) { return pad_label(pad); }
// The layout the gamepad cells show: the one in effect, or without a gamepad the one the setting names (Xbox for auto).
static int shown_layout(void) {
int l = input_pad_layout();
+2
View File
@@ -15,3 +15,5 @@ bool binds_modal(void);
// A key setting (TOTK_ name) as a row of one key cell, set by pressing the key as a binding's cell is; Delete sets it
// to none. note (NULL none) follows the description.
void binds_key_row(const char *setting, UiTextId label, UiTextId desc, const char *note);
// A gamepad input by position (PAD_*): the label the open pad has on a face button, else its place on the pad.
const char *binds_pad_label(int pad);
+32
View File
@@ -996,6 +996,37 @@ static void row_quicksave_keys(void) {
key_taken("TOTK_QUICKLOAD_KEY", note[1], sizeof note[1]));
}
// The free camera (freecam.c). Its switch is the patch set of the hook, read at start, so it is off by default and the
// row says "after restart". Then the combo: the trigger and shoulder pairs with a stick click, named as the open pad
// labels its buttons, or none; totk.ini takes any combo of button positions, shown as written. The key is any key or
// mouse button, taken by the bindings' capture window (binds_key_row) as quick save's are; Delete leaves it without
// one. A key the bindings also use says which action it presses. On other game versions the switch and the combo are
// greyed, and while the hook does not run (the switch off, or on but not yet restarted) the combo is greyed; the key
// row, which opt_disable_next does not grey, says why in its note.
static void rows_freecam(void) {
UiTextId why = rt_game_version != 143 ? UI_MENU_FREECAM_PAD_V143 : UI_MENU_FREECAM_OFF_NOTE;
if (rt_game_version != 143) opt_disable_next(UI_MENU_FREECAM_PAD_V143);
opt_toggle("TOTK_FREECAM_PATCH", UI_MENU_FREECAM, UI_MENU_FREECAM_DESC);
static const char *const combos[] = {"zl+zr+lstick", "zl+zr+rstick", "l+r+lstick", "l+r+rstick", "none"};
static const int pads[][3] = {{PAD_ZL, PAD_ZR, PAD_LSTICK}, {PAD_ZL, PAD_ZR, PAD_RSTICK},
{PAD_L, PAD_R, PAD_LSTICK}, {PAD_L, PAD_R, PAD_RSTICK}};
enum { N = sizeof combos / sizeof *combos };
static char shown[N - 1][128];
const char *names[N];
for (int i = 0; i < N - 1; i++) {
snprintf(shown[i], sizeof shown[i], "%s + %s + %s", binds_pad_label(pads[i][0]), binds_pad_label(pads[i][1]),
binds_pad_label(pads[i][2]));
names[i] = shown[i];
}
names[N - 1] = menu_text(UI_MENU_OFF);
if (!freecam_available()) opt_disable_next(why);
opt_choice_list("TOTK_FREECAM_PAD", UI_MENU_FREECAM_PAD, combos, names, N, UI_MENU_FREECAM_PAD_DESC);
static char note[64];
binds_key_row("TOTK_FREECAM_KEY", UI_MENU_FREECAM_KEY, UI_MENU_FREECAM_KEY_DESC,
freecam_available() ? key_taken("TOTK_FREECAM_KEY", note, sizeof note)
: menu_text(why));
}
// The note under the prompts. The settings name a folder of prompts (input_prompts_folder: the prompts and the pad
// layout, as a layout that puts A on the right button needs the face buttons named the other way round), but the game
// reads its fonts and UI archive once at start (romfs.c overlay_init). While the folder in use differs: when the
@@ -1136,6 +1167,7 @@ static void tab_controls(float scale) {
row_quicksave_keys();
row_walk_key();
opt_slider("TOTK_WALK_SCALE", UI_MENU_WALK_SCALE, 0.2f, 0.9f, UI_MENU_WALK_SCALE_DESC, 0.01f, "%.2f");
rows_freecam();
rows_gameplay_tweaks();
// Analog sticks: one dead zone row per stick, falling back to TOTK_STICK_DEADZONE (both sticks) while unset. With
// a gamepad connected each row shows its stick's deflection now, before the dead zone: a drifting stick's resting