Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/master'
Browse files Browse the repository at this point in the history
  • Loading branch information
ethanaobrien committed Jan 16, 2024
2 parents 00f4e2e + fdc7fe5 commit bce4c26
Show file tree
Hide file tree
Showing 111 changed files with 7,803 additions and 2,352 deletions.
85 changes: 85 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,89 @@
# Future
- ACCESSIBILITY/TTS: fix target language and missing espeak handling on Linux
- AI: AI service reworked: performance increase, automatic translation, configurable subtitle placement, and more
- APPLE: Fix WebDAV crash with digest auth (Cloud Sync)
- APPLE: Cloud sync fixes - ignore .DS_Store files and re-sync on app foreground
- AUDIO/SYNC: Handle Hz skew adjustment for high refresh rates better (BFI, swap interval)
- AUDIO/MIXER: Separate ffmpeg/mpv and audiomixer conditionals
- AUDIO/WASAPI: Reworked shared buffer operation for more flexibility, fixed exclusive mode last buffer looping when entering menu
- CONFIG/OVERRIDES: Fix setting savefile_directory in override file
- CONFIG: Force fixed locale for numbers
- CHEEVOS: Upgrade to rcheevos 11.0
- CHEEVOS: Use rc_client for state management
- CHEEVOS: Don't track disc changes when achievements are disabled
- CHEEVOS: Reinitialize rewind buffer after loading game with achievements
- CHEEVOS: Inform user when server is unreachable
- CHEEVOS: Fix crash on first load of game with achievements with threaded video
- EMSCRIPTEN: Increase chunk size for reads/writes
- EMSCRIPTEN: Modularize the JavaScript and clean up the web build
- EMSCRIPTEN: Prefix core name with libretro_ for exports
- EMSCRIPTEN: replace dashes with underscores in corenames (fix for vitaquake cores)
- EMSCRIPTEN: Use ZipFS for web player asset bundle
- IOS: Fix widget on IOS17
- IOS: Exit instead of crash on some errors
- IOS: Fix ios-vulkan-ppsspp
- IOS: Enable HDR support on IOS
- IOS: Add option to disable respecting silent mode
- IOS: Allow ignoring safe area (fullscreen over notch)
- IOS: Default to not enabling keyboard gamepad
- IOS: Fix XRGB8888 in GL driver
- IOS: Allow changing the app icon
- IOS/TVOS: Create GL context as GLES3 to fix some rendering performance problems
- INPUT: Default 'Bind Hold' to 0 to prevent problems with controllers not resting at null state
- INPUT: Add a setting to allow turbo d-pad directions
- INPUT/UDEV: Change event detection to polling in udev_joypad
- LAKKA: Add new menu options for Switch (overclock, CEC, BT ERTM)
- LIBRETRO/NETPACKET:
Switch environment call number from 76 to 78 (retire 76 as it was never used by any core)
Simplify broadcasts by removing the option to send to all but one client, use an explicit RETRO_NETPACKET_BROADCAST constant instead
Separate explicit flushing and querying of incoming packet into two operations
Enable a core to specify a protocol version string which can get used instead of core version to determine compatibility between two players
Log and notify a separate message when there is a content crc mismatch while using this interface to convey it being less severe
- MENU: Fix menu analog stick navigation (1.16.0.1)
- MENU: Add option to find thumbnail images by playlist rom filename (1.16.0.2)
- MENU: Don't process menu events while input is being flushed (1.16.0.2)
- MENU: Prevent proceeding to next bind when single binding (1.16.0.3)
- MENU: Fix touchscreen menu false positives in case of overlap
- MENU: Sort playlists ignoring extension (Playstation 2 should come after Playstation)
- MENU: Treat System Volume Information folder as hidden on all platforms
- MENU: Add Belarusian language option
- MENU: Fix savestate thumbnail behavior when navigating back to playlist while content is still running
- MENU: Fix word wrapped widget length
- MENU: Add help text to controller drivers
- MENU: Fix quit on content close option
- MENU: Fix thumbnails in History for content loaded through Load Content
- MENU: Flexible thumbnail matching (ROM name - database name - short name)
- MENU/GLUI: Icon corrections
- MENU/OZONE: Thumbnail related fixes (missing thumbnail bar, fullscreen thumbnail flashing, sidebar focus)
- MENU/RGUI: Fix text scaling in 16:9
- MENU/XMB: Background images take precedence over color themes, default image opacity set the same as color theme opacity
- MENU/XMB: Fix segmentation fault when background image is missing
- MENU/XMB: Several corrections and cleanups
- NETWORKING/NETPLAY: Add support for joining MITM servers from command line
- NETWORKING/NETPACKET: Interface connection flow improvements
- OSX: Fix mouse support for MelonDS DS on OSX
- PATCHES: Add support for XDelta-formatted patches.
- PATCHES: Fix patching for cores that support contentless mode
- PS2: Fix for no sound
- PS2: Fix 0-byte logs and add memory stats
- PSP: Fix memory leak in audio driver
- RUNLOOP: Frame Rest, experimental sleep feature aiming to lower CPU usage and temperature when using certain CPU hungry vsync modes
- RPI: Fix videocore + switchres compile failure
- TVOS: Enable overlay support
- VIDEO/GLSL: Add FinalViewportSize support to GLSL
- VIDEO/GLSL: Change rotation type to int to maximize compatibility
- VIDEO: Use video refresh rate instead of core refresh rate for menu frame limiting
- VIDEO: Enforce swap interval 1 in menu if vsync is on
- WIIU: Fix config file and core info reading
- WIIU: Fix "Up" and "Left" directional input for both Analog sticks for GC Adapter
- WIIU: Fix 3 USB controllers (NES/SNES/Retrode)
- WIIU: Fix file descriptor leak
- WIN32: Prefer D3D11 and WASAPI as default video and audio drivers
- WIN32: Fix window size when aspect ratio is < 0
- WIN32: Fix screen resolution always tied to the main monitor
- WAYLAND: Enable fallback for screensaver inhibit via D-Bus
- WAYLAND: Introduce wp_fractional_scale_v1 protocol for proper fractional scaling
- WAYLAND: Update wayland-protocols version to 1.31

# 1.16.0
- 3DS: Update __system_initArgv
Expand All @@ -25,6 +109,7 @@ require fullpath or not, small and big ZIP files).
- APPLE: Don't include MoltenVK library in Load Core menu list
- APPLE: Enable AltServer JIT for builds installed by Xcode
- APPLE: The default pthread stack size on Apple is too small for detect_ps2_game, so increase it
- APPLE: Introduce Cloud Sync via a WebDAV service on iOS/TVOS/MacOS
- CHEEVOS: Upgrade to rcheevos 10.7
- CHEEVOS: Don't initialize rcheevos memory unless used
- CHEEVOS: Add progress tracker widget
Expand Down
1 change: 1 addition & 0 deletions Makefile.common
Original file line number Diff line number Diff line change
Expand Up @@ -269,6 +269,7 @@ ifeq ($(HAVE_PATCH), 1)
endif

OBJ += \
save.o \
tasks/task_save.o \
tasks/task_movie.o \
tasks/task_file_transfer.o \
Expand Down
4 changes: 3 additions & 1 deletion Makefile.wii
Original file line number Diff line number Diff line change
Expand Up @@ -162,8 +162,9 @@ HAVE_XMB := 0
HAVE_OZONE := 0
HAVE_RGUI := 1
HAVE_MATERIALUI := 0
HAVE_CHEEVOS := 1

CFLAGS += -DHAVE_SOCKET_LEGACY
CFLAGS += -DHAVE_SOCKET_LEGACY -DHAVE_CHEEVOS

APP_BOOTER_DIR = wii/app_booter
PLATOBJS := $(APP_BOOTER_DIR)/app_booter.binobj
Expand All @@ -174,6 +175,7 @@ endif

INCLUDE += -I./libretro-common/include \
-Ideps \
-Ideps/rcheevos/include \
-Ideps/stb
CFLAGS += -Wall -std=gnu99 $(MACHDEP) $(PLATCFLAGS) $(INCLUDE)

Expand Down
34 changes: 24 additions & 10 deletions audio/drivers/wasapi.c
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ static void *wasapi_init(const char *dev_id, unsigned rate, unsigned latency,
return NULL;
}

static bool wasapi_flush(wasapi_t * w, const void * data, size_t size)
static bool wasapi_flush(wasapi_t *w, const void *data, size_t size)
{
BYTE *dest = NULL;
UINT32 frame_count = size / w->frame_size;
Expand All @@ -173,7 +173,7 @@ static bool wasapi_flush(wasapi_t * w, const void * data, size_t size)
return true;
}

static bool wasapi_flush_buffer(wasapi_t * w, size_t size)
static bool wasapi_flush_buffer(wasapi_t *w, size_t size)
{
BYTE *dest = NULL;
UINT32 frame_count = size / w->frame_size;
Expand All @@ -191,7 +191,7 @@ static bool wasapi_flush_buffer(wasapi_t * w, size_t size)
return true;
}

static ssize_t wasapi_write_sh_buffer(wasapi_t *w, const void * data, size_t size)
static ssize_t wasapi_write_sh_buffer(wasapi_t *w, const void *data, size_t size)
{
ssize_t written = -1;
size_t write_avail = FIFO_WRITE_AVAIL(w->buffer);
Expand Down Expand Up @@ -222,7 +222,7 @@ static ssize_t wasapi_write_sh_buffer(wasapi_t *w, const void * data, size_t siz
return written;
}

static ssize_t wasapi_write_sh(wasapi_t *w, const void * data, size_t size)
static ssize_t wasapi_write_sh(wasapi_t *w, const void *data, size_t size)
{
ssize_t written = -1;
size_t write_avail = 0;
Expand All @@ -246,7 +246,7 @@ static ssize_t wasapi_write_sh(wasapi_t *w, const void * data, size_t size)
return written;
}

static ssize_t wasapi_write_sh_nonblock(wasapi_t *w, const void * data, size_t size)
static ssize_t wasapi_write_sh_nonblock(wasapi_t *w, const void *data, size_t size)
{
ssize_t written = -1;
size_t write_avail = 0;
Expand Down Expand Up @@ -291,7 +291,7 @@ static ssize_t wasapi_write_sh_nonblock(wasapi_t *w, const void * data, size_t s
return written;
}

static ssize_t wasapi_write_ex(wasapi_t *w, const void * data, size_t size, DWORD ms)
static ssize_t wasapi_write_ex(wasapi_t *w, const void *data, size_t size, DWORD ms)
{
ssize_t written = 0;
size_t write_avail = FIFO_WRITE_AVAIL(w->buffer);
Expand Down Expand Up @@ -395,10 +395,23 @@ static bool wasapi_alive(void *wh)
return w->running;
}

static void wasapi_insert_silence(wasapi_t *w)
{
int i;

for (i = 0; i < 12; i++)
audio_driver_menu_sample();
}

static void wasapi_set_nonblock_state(void *wh, bool nonblock)
{
wasapi_t *w = (wasapi_t*)wh;

/* Since exclusive mode keeps repeating last sample while
* in paused menu, generate some silence first. */
if (!nonblock && w->exclusive)
wasapi_insert_silence(w);

w->nonblock = nonblock;
}

Expand Down Expand Up @@ -447,20 +460,21 @@ static size_t wasapi_write_avail(void *wh)
wasapi_t *w = (wasapi_t*)wh;
UINT32 padding = 0;

if (w->buffer)
return FIFO_WRITE_AVAIL(w->buffer);

if (FAILED(_IAudioClient_GetCurrentPadding(w->client, &padding)))
return 0;

if (w->buffer)
/* Exaggarate available size for best results.. */
return FIFO_WRITE_AVAIL(w->buffer) + padding * 2;

return w->engine_buffer_size - padding * w->frame_size;
}

static size_t wasapi_buffer_size(void *wh)
{
wasapi_t *w = (wasapi_t*)wh;

if (!w->exclusive && w->buffer)
if (w->buffer)
return w->buffer->size;

return w->engine_buffer_size;
Expand Down
12 changes: 3 additions & 9 deletions command.c
Original file line number Diff line number Diff line change
Expand Up @@ -1258,20 +1258,14 @@ bool command_event_resize_windowed_scale(settings_t *settings,
return true;
}

bool command_event_save_auto_state(
bool savestate_auto_save,
const enum rarch_core_type current_core_type)
bool command_event_save_auto_state(void)
{
size_t _len;
runloop_state_t *runloop_st = runloop_state_get_ptr();
char savestate_name_auto[PATH_MAX_LENGTH];

if (runloop_st->entry_state_slot)
return false;
if (!savestate_auto_save)
return false;
if (current_core_type == CORE_TYPE_DUMMY)
return false;
if (!core_info_current_supports_savestate())
return false;
if (string_is_empty(path_basename(path_get(RARCH_PATH_BASENAME))))
Expand All @@ -1284,7 +1278,7 @@ bool command_event_save_auto_state(
".auto",
sizeof(savestate_name_auto) - _len);

if (content_save_state((const char*)savestate_name_auto, true, true))
if (content_auto_save_state((const char*)savestate_name_auto))
RARCH_LOG("%s \"%s\" %s.\n",
msg_hash_to_str(MSG_AUTO_SAVE_STATE_TO),
savestate_name_auto, "succeeded");
Expand Down Expand Up @@ -1988,7 +1982,7 @@ bool command_event_main_state(unsigned cmd)
settings->bools.frame_time_counter_reset_after_save_state;

if (cmd == CMD_EVENT_SAVE_STATE)
content_save_state(state_path, true, false);
content_save_state(state_path, true);
else
content_save_state_to_ram();

Expand Down
4 changes: 1 addition & 3 deletions command.h
Original file line number Diff line number Diff line change
Expand Up @@ -349,9 +349,7 @@ void command_event_set_mixer_volume(
bool command_event_resize_windowed_scale(settings_t *settings,
unsigned window_scale);

bool command_event_save_auto_state(
bool savestate_auto_save,
const enum rarch_core_type current_core_type);
bool command_event_save_auto_state(void);

/**
* event_set_volume:
Expand Down
6 changes: 5 additions & 1 deletion config.def.h
Original file line number Diff line number Diff line change
Expand Up @@ -701,8 +701,10 @@
#ifdef HAVE_MIST
#define DEFAULT_MENU_SHOW_CORE_MANAGER_STEAM true
#endif
#if 0
/* Thumbnailpack removal */
#define DEFAULT_MENU_SHOW_LEGACY_THUMBNAIL_UPDATER false

#endif
#define DEFAULT_MENU_SHOW_SUBLABELS true
#define DEFAULT_MENU_DYNAMIC_WALLPAPER_ENABLE true
#define DEFAULT_MENU_SCROLL_FAST false
Expand Down Expand Up @@ -1440,6 +1442,8 @@

#define DEFAULT_SCAN_WITHOUT_CORE_MATCH false

#define DEFAULT_SCAN_SERIAL_AND_CRC false

#ifdef __WINRT__
/* Be paranoid about WinRT file I/O performance, and leave this disabled by
* default */
Expand Down
12 changes: 11 additions & 1 deletion configuration.c
Original file line number Diff line number Diff line change
Expand Up @@ -1657,6 +1657,7 @@ static struct config_path_setting *populate_settings_path(
#endif

SETTING_ARRAY("log_dir", settings->paths.log_dir, true, NULL, true);
SETTING_ARRAY("app_icon", settings->paths.app_icon, true, NULL, true);

*size = count;

Expand Down Expand Up @@ -1733,6 +1734,7 @@ static struct config_bool_setting *populate_settings_bool(
SETTING_BOOL("global_core_options", &settings->bools.global_core_options, true, DEFAULT_GLOBAL_CORE_OPTIONS, false);
SETTING_BOOL("auto_shaders_enable", &settings->bools.auto_shaders_enable, true, DEFAULT_AUTO_SHADERS_ENABLE, false);
SETTING_BOOL("scan_without_core_match", &settings->bools.scan_without_core_match, true, DEFAULT_SCAN_WITHOUT_CORE_MATCH, false);
SETTING_BOOL("scan_serial_and_crc", &settings->bools.scan_serial_and_crc, true, DEFAULT_SCAN_SERIAL_AND_CRC, false);
SETTING_BOOL("sort_savefiles_enable", &settings->bools.sort_savefiles_enable, true, DEFAULT_SORT_SAVEFILES_ENABLE, false);
SETTING_BOOL("sort_savestates_enable", &settings->bools.sort_savestates_enable, true, DEFAULT_SORT_SAVESTATES_ENABLE, false);
SETTING_BOOL("sort_savefiles_by_content_enable", &settings->bools.sort_savefiles_by_content_enable, true, DEFAULT_SORT_SAVEFILES_BY_CONTENT_ENABLE, false);
Expand Down Expand Up @@ -1985,7 +1987,10 @@ static struct config_bool_setting *populate_settings_bool(
SETTING_BOOL("menu_show_shutdown", &settings->bools.menu_show_shutdown, true, DEFAULT_MENU_SHOW_SHUTDOWN, false);
SETTING_BOOL("menu_show_online_updater", &settings->bools.menu_show_online_updater, true, DEFAULT_MENU_SHOW_ONLINE_UPDATER, false);
SETTING_BOOL("menu_show_core_updater", &settings->bools.menu_show_core_updater, true, DEFAULT_MENU_SHOW_CORE_UPDATER, false);
#if 0
/* Thumbnailpack removal */
SETTING_BOOL("menu_show_legacy_thumbnail_updater", &settings->bools.menu_show_legacy_thumbnail_updater, true, DEFAULT_MENU_SHOW_LEGACY_THUMBNAIL_UPDATER, false);
#endif
#ifdef HAVE_MIST
SETTING_BOOL("menu_show_core_manager_steam", &settings->bools.menu_show_core_manager_steam, true, DEFAULT_MENU_SHOW_CORE_MANAGER_STEAM, false);
#endif
Expand Down Expand Up @@ -5014,9 +5019,14 @@ bool config_save_autoconf_profile(const
{
const struct retro_keybind *bind = &input_config_binds[user][i];
if (bind->valid)
input_config_save_keybind(
{
save_keybind_joykey(
conf, "input", input_config_bind_map_get_base(i),
bind, false);
save_keybind_axis(
conf, "input", input_config_bind_map_get_base(i),
bind, false);
}
}

ret = config_file_write(conf, autoconf_file, false);
Expand Down
5 changes: 5 additions & 0 deletions configuration.h
Original file line number Diff line number Diff line change
Expand Up @@ -563,6 +563,7 @@ typedef struct settings
char directory_bottom_assets[PATH_MAX_LENGTH];
#endif
char log_dir[PATH_MAX_LENGTH];
char app_icon[PATH_MAX_LENGTH];
} paths;

bool modified;
Expand Down Expand Up @@ -749,7 +750,10 @@ typedef struct settings
bool menu_show_latency;
bool menu_show_rewind;
bool menu_show_overlays;
#if 0
/* Thumbnailpack removal */
bool menu_show_legacy_thumbnail_updater;
#endif
bool menu_materialui_icons_enable;
bool menu_materialui_playlist_icons_enable;
bool menu_materialui_switch_icons;
Expand Down Expand Up @@ -1027,6 +1031,7 @@ typedef struct settings
bool log_to_file_timestamp;

bool scan_without_core_match;
bool scan_serial_and_crc;

bool ai_service_enable;
bool ai_service_pause;
Expand Down
11 changes: 4 additions & 7 deletions content.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,6 @@ typedef struct content_ctx_info
int argc; /* Argument count. */
} content_ctx_info_t;

/* Load a RAM state from disk to memory. */
bool content_load_ram_file(unsigned slot);

/* Save a RAM state from memory to disk. */
bool content_save_ram_file(unsigned slot, bool compress);

/* Load a state from memory. */
bool content_load_state_from_ram(void);

Expand All @@ -58,7 +52,10 @@ bool content_ram_state_to_file(const char *path);
bool content_load_state(const char* path, bool load_to_backup_buffer, bool autoload);

/* Save a state from memory to disk. */
bool content_save_state(const char *path, bool save_to_disk, bool autosave);
bool content_save_state(const char *path, bool save_to_disk);

/* Save an automatic savestate to disk. */
bool content_auto_save_state(const char *path);

/* Check a ram state write to disk. */
bool content_ram_state_pending(void);
Expand Down
Loading

0 comments on commit bce4c26

Please sign in to comment.