Merge pull request #1 from libretro/master

Merge new changes
This commit is contained in:
Weedy Weed Smoker 2019-05-06 02:00:06 +07:00 committed by GitHub
commit f1a060cc5a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
28 changed files with 245 additions and 172 deletions

View File

@ -3750,3 +3750,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -4764,3 +4764,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -3522,3 +3522,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -3651,3 +3651,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -7728,3 +7728,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -3410,3 +3410,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -7880,3 +7880,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -8657,3 +8657,5 @@ MSG_HASH(
MENU_ENUM_SUBLABEL_LOG_DIR,
"Les fichiers de journalisation des événements système seront conservés dans ce dossier."
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -3635,3 +3635,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -4204,3 +4204,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -3503,3 +3503,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -1841,3 +1841,5 @@ MSG_HASH(MENU_ENUM_LABEL_LOG_DIR,
"log_dir")
MSG_HASH(MENU_ENUM_LABEL_MENU_WIDGETS_ENABLE,
"menu_widgets_enable")
MSG_HASH(MENU_ENUM_LABEL_VIDEO_SHADERS_ENABLE,
"video_shader_enable")

View File

@ -3404,3 +3404,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -3800,3 +3800,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu widgetów")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -8032,3 +8032,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -3476,3 +3476,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -3679,3 +3679,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -8548,3 +8548,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -8663,3 +8663,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -3566,3 +3566,5 @@ MSG_HASH(
)
MSG_HASH(MENU_ENUM_LABEL_VALUE_MENU_WIDGETS_ENABLE,
"Menu Widgets")
MSG_HASH(MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
"Video Shaders")

View File

@ -68,6 +68,7 @@ IDR_MENU MENU
MENUITEM "9x", ID_M_WINDOW_SCALE_9X
MENUITEM "10x", ID_M_WINDOW_SCALE_10X
}
MENUITEM "Toggle Desktop Menu", ID_M_TOGGLE_DESKTOP
MENUITEM "Toggle Exclusive Full Screen", ID_M_FULL_SCREEN
// Shader dialog is disabled for now, until video_threaded issues are fixed.
//MENUITEM "Shader Parameters", ID_M_SHADER_PARAMETERS

View File

@ -65,6 +65,7 @@ IDR_MENU MENU
MENUITEM "9x", ID_M_WINDOW_SCALE_9X
MENUITEM "10x", ID_M_WINDOW_SCALE_10X
}
MENUITEM "Toggle Desktop Menu", ID_M_TOGGLE_DESKTOP
MENUITEM "排他的なフルスクリーン切り替え", ID_M_FULL_SCREEN
// Shader dialog is disabled for now, until video_threaded issues are fixed.
//MENUITEM "シェーダーのパラメータ", ID_M_SHADER_PARAMETERS

View File

@ -23,6 +23,7 @@
#include <limits.h>
#include <compat/posix_string.h>
#include <compat/strcasestr.h>
#include <compat/strl.h>
#include <file/file_path.h>
#include <formats/image.h>
@ -2490,8 +2491,7 @@ static void materialui_list_insert(void *userdata,
node->texture_switch2_set = true;
}
else if (
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ADD_TO_FAVORITES))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ADD_TO_FAVORITES)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ADD_TO_FAVORITES_PLAYLIST)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_GOTO_FAVORITES))
)
@ -2607,24 +2607,15 @@ static void materialui_list_insert(void *userdata,
node->texture_switch2_set = true;
}
else if (
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ONLINE_UPDATER))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_CORE_INFO_FILES))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_AUTOCONFIG_PROFILES))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_ASSETS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_CHEATS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_DATABASES))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_OVERLAYS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_CG_SHADERS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_GLSL_SHADERS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ONLINE_UPDATER)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_CORE_INFO_FILES)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_AUTOCONFIG_PROFILES)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_ASSETS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_CHEATS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_DATABASES)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_OVERLAYS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_CG_SHADERS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_GLSL_SHADERS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATE_SLANG_SHADERS))
)
{
@ -2644,78 +2635,47 @@ static void materialui_list_insert(void *userdata,
node->texture_switch2_set = true;
}
else if (
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_MENU_FILE_BROWSER_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_DRIVER_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_AUDIO_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_AUDIO_MIXER_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_INPUT_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_LATENCY_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_INPUT_HOTKEY_BINDS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_CORE_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_CONFIGURATION_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_SAVING_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_LOGGING_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_FRAME_THROTTLE_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_RECORDING_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ONSCREEN_DISPLAY_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_USER_INTERFACE_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_RETRO_ACHIEVEMENTS_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_WIFI_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_NETWORK_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_NETPLAY_LAN_SCAN_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_LAKKA_SERVICES))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_PLAYLIST_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_USER_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_DIRECTORY_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_PRIVACY_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_MIDI_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_MENU_VIEWS_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_QUICK_MENU_VIEWS_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_MENU_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ONSCREEN_OVERLAY_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ONSCREEN_NOTIFICATIONS_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ACCOUNTS_LIST))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_REWIND_SETTINGS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ACCOUNTS_RETRO_ACHIEVEMENTS))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_CORE_UPDATER_LIST))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_THUMBNAILS_UPDATER_LIST))
||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_MENU_FILE_BROWSER_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_DRIVER_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_AUDIO_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_AUDIO_MIXER_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_MENU_SOUNDS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_INPUT_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_LATENCY_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_INPUT_HOTKEY_BINDS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_CORE_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_CONFIGURATION_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_CRT_SWITCHRES_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_SAVING_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_LOGGING_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_FRAME_THROTTLE_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_RECORDING_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ONSCREEN_DISPLAY_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_USER_INTERFACE_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_RETRO_ACHIEVEMENTS_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ACCOUNTS_YOUTUBE)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ACCOUNTS_TWITCH)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_WIFI_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_NETWORK_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_NETPLAY_LAN_SCAN_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_LAKKA_SERVICES)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_PLAYLIST_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_USER_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_DIRECTORY_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_PRIVACY_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_MIDI_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_MENU_VIEWS_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_QUICK_MENU_VIEWS_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_MENU_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ONSCREEN_OVERLAY_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ONSCREEN_NOTIFICATIONS_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ACCOUNTS_LIST)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_REWIND_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_ACCOUNTS_RETRO_ACHIEVEMENTS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_CORE_UPDATER_LIST)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_THUMBNAILS_UPDATER_LIST)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_UPDATER_SETTINGS)) ||
string_is_equal(label, msg_hash_to_str(MENU_ENUM_LABEL_DOWNLOAD_CORE_CONTENT_DIRS))
)
{
@ -2730,6 +2690,24 @@ static void materialui_list_insert(void *userdata,
node->texture_switch2_index = MUI_TEXTURE_FOLDER;
node->texture_switch2_set = true;
}
else if (strcasestr(label, "_input_binds_list"))
{
unsigned i;
for (i = 0; i < MAX_USERS; i++)
{
char val[255];
unsigned user_value = i + 1;
snprintf(val, sizeof(val), "%d_input_binds_list", user_value);
if (string_is_equal(label, val))
{
node->texture_switch2_index = MUI_TEXTURE_SETTINGS;
node->texture_switch2_set = true;
}
}
}
break;
}
}

View File

@ -4718,95 +4718,104 @@ bool menu_displaylist_ctl(enum menu_displaylist_ctl_state type,
unsigned i;
struct video_shader *shader = menu_shader_get();
unsigned pass_count = shader ? shader->passes : 0;
settings_t *settings = config_get_ptr();
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SHADER_APPLY_CHANGES),
msg_hash_to_str(MENU_ENUM_LABEL_SHADER_APPLY_CHANGES),
MENU_ENUM_LABEL_SHADER_APPLY_CHANGES,
MENU_SETTING_ACTION, 0, 0))
if (menu_displaylist_parse_settings_enum(info->list,
MENU_ENUM_LABEL_VIDEO_SHADERS_ENABLE,
PARSE_ONLY_BOOL, false) == 0)
count++;
if (frontend_driver_can_watch_for_changes())
if (settings->bools.video_shader_enable)
{
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SHADER_WATCH_FOR_CHANGES),
msg_hash_to_str(MENU_ENUM_LABEL_SHADER_WATCH_FOR_CHANGES),
MENU_ENUM_LABEL_SHADER_WATCH_FOR_CHANGES,
0, 0, 0))
count++;
}
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PRESET),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PRESET),
MENU_ENUM_LABEL_VIDEO_SHADER_PRESET,
FILE_TYPE_PATH, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PRESET_SAVE_AS),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_AS),
MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_AS,
MENU_SETTING_ACTION, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PRESET_SAVE_CORE),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_CORE),
MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_CORE,
MENU_SETTING_ACTION, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PRESET_SAVE_PARENT),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_PARENT),
MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_PARENT,
MENU_SETTING_ACTION, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PRESET_SAVE_GAME),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_GAME),
MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_GAME,
MENU_SETTING_ACTION, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PARAMETERS),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PARAMETERS),
MENU_ENUM_LABEL_VIDEO_SHADER_PARAMETERS,
MENU_SETTING_ACTION, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_NUM_PASSES),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_NUM_PASSES),
MENU_ENUM_LABEL_VIDEO_SHADER_NUM_PASSES,
0, 0, 0))
count++;
for (i = 0; i < pass_count; i++)
{
char buf_tmp[64];
char buf[128];
buf[0] = buf_tmp[0] = '\0';
snprintf(buf_tmp, sizeof(buf_tmp),
"%s #%u", msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SHADER), i);
if (menu_entries_append_enum(info->list, buf_tmp,
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PASS),
MENU_ENUM_LABEL_VIDEO_SHADER_PASS,
MENU_SETTINGS_SHADER_PASS_0 + i, 0, 0))
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SHADER_APPLY_CHANGES),
msg_hash_to_str(MENU_ENUM_LABEL_SHADER_APPLY_CHANGES),
MENU_ENUM_LABEL_SHADER_APPLY_CHANGES,
MENU_SETTING_ACTION, 0, 0))
count++;
snprintf(buf, sizeof(buf), "%s %s", buf_tmp, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_FILTER));
if (menu_entries_append_enum(info->list, buf,
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_FILTER_PASS),
MENU_ENUM_LABEL_VIDEO_SHADER_FILTER_PASS,
MENU_SETTINGS_SHADER_PASS_FILTER_0 + i, 0, 0))
if (frontend_driver_can_watch_for_changes())
{
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SHADER_WATCH_FOR_CHANGES),
msg_hash_to_str(MENU_ENUM_LABEL_SHADER_WATCH_FOR_CHANGES),
MENU_ENUM_LABEL_SHADER_WATCH_FOR_CHANGES,
0, 0, 0))
count++;
}
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PRESET),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PRESET),
MENU_ENUM_LABEL_VIDEO_SHADER_PRESET,
FILE_TYPE_PATH, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PRESET_SAVE_AS),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_AS),
MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_AS,
MENU_SETTING_ACTION, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PRESET_SAVE_CORE),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_CORE),
MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_CORE,
MENU_SETTING_ACTION, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PRESET_SAVE_PARENT),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_PARENT),
MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_PARENT,
MENU_SETTING_ACTION, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PRESET_SAVE_GAME),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_GAME),
MENU_ENUM_LABEL_VIDEO_SHADER_PRESET_SAVE_GAME,
MENU_SETTING_ACTION, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_PARAMETERS),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PARAMETERS),
MENU_ENUM_LABEL_VIDEO_SHADER_PARAMETERS,
MENU_SETTING_ACTION, 0, 0))
count++;
if (menu_entries_append_enum(info->list,
msg_hash_to_str(MENU_ENUM_LABEL_VALUE_VIDEO_SHADER_NUM_PASSES),
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_NUM_PASSES),
MENU_ENUM_LABEL_VIDEO_SHADER_NUM_PASSES,
0, 0, 0))
count++;
snprintf(buf, sizeof(buf), "%s %s", buf_tmp, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SCALE));
if (menu_entries_append_enum(info->list, buf,
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_SCALE_PASS),
MENU_ENUM_LABEL_VIDEO_SHADER_SCALE_PASS,
MENU_SETTINGS_SHADER_PASS_SCALE_0 + i, 0, 0))
count++;
for (i = 0; i < pass_count; i++)
{
char buf_tmp[64];
char buf[128];
buf[0] = buf_tmp[0] = '\0';
snprintf(buf_tmp, sizeof(buf_tmp),
"%s #%u", msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SHADER), i);
if (menu_entries_append_enum(info->list, buf_tmp,
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_PASS),
MENU_ENUM_LABEL_VIDEO_SHADER_PASS,
MENU_SETTINGS_SHADER_PASS_0 + i, 0, 0))
count++;
snprintf(buf, sizeof(buf), "%s %s", buf_tmp, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_FILTER));
if (menu_entries_append_enum(info->list, buf,
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_FILTER_PASS),
MENU_ENUM_LABEL_VIDEO_SHADER_FILTER_PASS,
MENU_SETTINGS_SHADER_PASS_FILTER_0 + i, 0, 0))
count++;
snprintf(buf, sizeof(buf), "%s %s", buf_tmp, msg_hash_to_str(MENU_ENUM_LABEL_VALUE_SCALE));
if (menu_entries_append_enum(info->list, buf,
msg_hash_to_str(MENU_ENUM_LABEL_VIDEO_SHADER_SCALE_PASS),
MENU_ENUM_LABEL_VIDEO_SHADER_SCALE_PASS,
MENU_SETTINGS_SHADER_PASS_SCALE_0 + i, 0, 0))
count++;
}
}
}

View File

@ -62,6 +62,7 @@
#include "menu_driver.h"
#include "menu_animation.h"
#include "menu_input.h"
#include "menu_shader.h"
#include "widgets/menu_input_dialog.h"
#include "widgets/menu_input_bind_dialog.h"
@ -5574,6 +5575,28 @@ void general_write_handler(rarch_setting_t *setting)
switch (setting->enum_idx)
{
case MENU_ENUM_LABEL_VIDEO_SHADERS_ENABLE:
{
if (*setting->value.target.boolean)
{
bool refresh = false;
menu_entries_ctl(MENU_ENTRIES_CTL_SET_REFRESH, &refresh);
menu_driver_ctl(RARCH_MENU_CTL_SET_PREVENT_POPULATE, NULL);
}
else if (!*setting->value.target.boolean)
{
bool refresh = false;
settings_t *settings = config_get_ptr();
struct video_shader *shader = menu_shader_get();
shader->passes = 0;
menu_entries_ctl(MENU_ENTRIES_CTL_SET_REFRESH, &refresh);
menu_driver_ctl(RARCH_MENU_CTL_SET_PREVENT_POPULATE, NULL);
command_event(CMD_EVENT_SHADERS_APPLY_CHANGES, NULL);
settings->bools.video_shader_enable = false;
}
}
case MENU_ENUM_LABEL_VIDEO_THREADED:
{
if (*setting->value.target.boolean)
@ -7276,6 +7299,21 @@ static bool setting_append_list(
bool_entries[i].flags);
}
CONFIG_BOOL(
list, list_info,
&settings->bools.video_shader_enable,
MENU_ENUM_LABEL_VIDEO_SHADERS_ENABLE,
MENU_ENUM_LABEL_VALUE_VIDEO_SHADERS_ENABLE,
shader_enable,
MENU_ENUM_LABEL_VALUE_OFF,
MENU_ENUM_LABEL_VALUE_ON,
&group_info,
&subgroup_info,
parent_group,
general_write_handler,
general_read_handler,
SD_FLAG_NONE);
END_SUB_GROUP(list, list_info, parent_group);
END_GROUP(list, list_info, parent_group);
}

View File

@ -561,6 +561,8 @@ enum msg_hash_enums
MENU_LABEL(SHADER_PIPELINE_BOKEH),
MENU_LABEL(SHADER_PIPELINE_SNOWFLAKE),
MENU_LABEL(VIDEO_SHADERS_ENABLE),
MENU_LABEL(MATERIALUI_MENU_HEADER_OPACITY),
MENU_LABEL(MATERIALUI_MENU_FOOTER_OPACITY),
MENU_ENUM_LABEL_VALUE_MATERIALUI_MENU_COLOR_THEME_BLUE,

View File

@ -237,6 +237,9 @@ LRESULT win32_menu_loop(HWND owner, WPARAM wparam)
case ID_M_QUIT:
do_wm_close = true;
break;
case ID_M_TOGGLE_DESKTOP:
cmd = CMD_EVENT_UI_COMPANION_TOGGLE;
break;
default:
if (mode >= ID_M_WINDOW_SCALE_1X && mode <= ID_M_WINDOW_SCALE_10X)
{

View File

@ -28,3 +28,4 @@
#define ID_M_STATE_INDEX_AUTO 40024
#define ID_M_TAKE_SCREENSHOT 40025
#define ID_M_MUTE_TOGGLE 40026
#define ID_M_TOGGLE_DESKTOP 40027