mirror of
https://github.com/libretro/RetroArch.git
synced 2024-10-08 15:13:24 +00:00
(Menu) Expose HW Shared Context in menu
This commit is contained in:
parent
24cb03367d
commit
83edfab974
@ -157,6 +157,7 @@ static void menu_common_entries_init(void *data, unsigned menu_type)
|
|||||||
break;
|
break;
|
||||||
case MENU_SETTINGS_VIDEO_OPTIONS:
|
case MENU_SETTINGS_VIDEO_OPTIONS:
|
||||||
file_list_clear(menu->selection_buf);
|
file_list_clear(menu->selection_buf);
|
||||||
|
file_list_push(menu->selection_buf, "HW Shared Context", MENU_SETTINGS_VIDEO_HW_SHARED_CONTEXT, 0);
|
||||||
#if defined(GEKKO) || defined(__CELLOS_LV2__)
|
#if defined(GEKKO) || defined(__CELLOS_LV2__)
|
||||||
file_list_push(menu->selection_buf, "Screen Resolution", MENU_SETTINGS_VIDEO_RESOLUTION, 0);
|
file_list_push(menu->selection_buf, "Screen Resolution", MENU_SETTINGS_VIDEO_RESOLUTION, 0);
|
||||||
#endif
|
#endif
|
||||||
@ -4478,6 +4479,23 @@ static int menu_common_setting_set(unsigned setting, unsigned action)
|
|||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
case MENU_SETTINGS_VIDEO_HW_SHARED_CONTEXT:
|
||||||
|
switch (action)
|
||||||
|
{
|
||||||
|
case MENU_ACTION_START:
|
||||||
|
g_settings.video.shared_context = video_shared_context;
|
||||||
|
break;
|
||||||
|
|
||||||
|
case MENU_ACTION_LEFT:
|
||||||
|
case MENU_ACTION_RIGHT:
|
||||||
|
case MENU_ACTION_OK:
|
||||||
|
g_settings.video.shared_context = !g_settings.video.shared_context;
|
||||||
|
break;
|
||||||
|
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
break;
|
||||||
case MENU_SETTINGS_VIDEO_VSYNC:
|
case MENU_SETTINGS_VIDEO_VSYNC:
|
||||||
switch (action)
|
switch (action)
|
||||||
{
|
{
|
||||||
@ -5031,6 +5049,9 @@ static void menu_common_setting_set_label(char *type_str, size_t type_str_size,
|
|||||||
case MENU_SETTINGS_VIDEO_VSYNC:
|
case MENU_SETTINGS_VIDEO_VSYNC:
|
||||||
strlcpy(type_str, g_settings.video.vsync ? "ON" : "OFF", type_str_size);
|
strlcpy(type_str, g_settings.video.vsync ? "ON" : "OFF", type_str_size);
|
||||||
break;
|
break;
|
||||||
|
case MENU_SETTINGS_VIDEO_HW_SHARED_CONTEXT:
|
||||||
|
strlcpy(type_str, g_settings.video.shared_context ? "ON" : "OFF", type_str_size);
|
||||||
|
break;
|
||||||
case MENU_SETTINGS_VIDEO_HARD_SYNC:
|
case MENU_SETTINGS_VIDEO_HARD_SYNC:
|
||||||
strlcpy(type_str, g_settings.video.hard_sync ? "ON" : "OFF", type_str_size);
|
strlcpy(type_str, g_settings.video.hard_sync ? "ON" : "OFF", type_str_size);
|
||||||
break;
|
break;
|
||||||
|
@ -33,6 +33,7 @@ typedef enum
|
|||||||
MENU_SETTINGS_GENERAL_OPTIONS = MENU_START_SCREEN + 1,
|
MENU_SETTINGS_GENERAL_OPTIONS = MENU_START_SCREEN + 1,
|
||||||
MENU_SETTINGS_VIDEO_OPTIONS,
|
MENU_SETTINGS_VIDEO_OPTIONS,
|
||||||
MENU_SETTINGS_VIDEO_OPTIONS_FIRST,
|
MENU_SETTINGS_VIDEO_OPTIONS_FIRST,
|
||||||
|
MENU_SETTINGS_VIDEO_HW_SHARED_CONTEXT,
|
||||||
MENU_SETTINGS_VIDEO_RESOLUTION,
|
MENU_SETTINGS_VIDEO_RESOLUTION,
|
||||||
MENU_SETTINGS_VIDEO_PAL60,
|
MENU_SETTINGS_VIDEO_PAL60,
|
||||||
MENU_SETTINGS_VIDEO_FILTER,
|
MENU_SETTINGS_VIDEO_FILTER,
|
||||||
|
@ -134,7 +134,7 @@
|
|||||||
# video_threaded = false
|
# video_threaded = false
|
||||||
|
|
||||||
# Use a shared context for HW rendered libretro cores.
|
# Use a shared context for HW rendered libretro cores.
|
||||||
# Avoids having to assume GL state changes inbetween frames.
|
# Avoids having to assume HW state changes inbetween frames.
|
||||||
# video_shared_context = false
|
# video_shared_context = false
|
||||||
|
|
||||||
# Smoothens picture with bilinear filtering. Should be disabled if using pixel shaders.
|
# Smoothens picture with bilinear filtering. Should be disabled if using pixel shaders.
|
||||||
|
Loading…
Reference in New Issue
Block a user