mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-12-06 07:12:28 +01:00
overlays: add settings for screenshot and recording hints
Some checks failed
Generate Translation Template / Generate Translation Template (push) Has been cancelled
Build RPCS3 / RPCS3 Linux ${{ matrix.os }} ${{ matrix.compiler }} (/rpcs3/.ci/build-linux-aarch64.sh, gcc, rpcs3/rpcs3-ci-jammy-aarch64:1.6, ubuntu-24.04-arm) (push) Has been cancelled
Build RPCS3 / RPCS3 Linux ${{ matrix.os }} ${{ matrix.compiler }} (/rpcs3/.ci/build-linux.sh, gcc, rpcs3/rpcs3-ci-jammy:1.6, ubuntu-24.04) (push) Has been cancelled
Build RPCS3 / RPCS3 Linux ${{ matrix.os }} ${{ matrix.compiler }} (a1d35836e8d45bfc6f63c26f0a3e5d46ef622fe1, rpcs3/rpcs3-binaries-linux-arm64, /rpcs3/.ci/build-linux-aarch64.sh, clang, rpcs3/rpcs3-ci-jammy-aarch64:1.6, ubuntu-24.04-arm) (push) Has been cancelled
Build RPCS3 / RPCS3 Linux ${{ matrix.os }} ${{ matrix.compiler }} (d812f1254a1157c80fd402f94446310560f54e5f, rpcs3/rpcs3-binaries-linux, /rpcs3/.ci/build-linux.sh, clang, rpcs3/rpcs3-ci-jammy:1.6, ubuntu-24.04) (push) Has been cancelled
Build RPCS3 / RPCS3 Mac ${{ matrix.name }} (51ae32f468089a8169aaf1567de355ff4a3e0842, rpcs3/rpcs3-binaries-mac, arch -X86_64 .ci/build-mac.sh, Intel) (push) Has been cancelled
Build RPCS3 / RPCS3 Mac ${{ matrix.name }} (8e21bdbc40711a3fccd18fbf17b742348b0f4281, rpcs3/rpcs3-binaries-mac-arm64, .ci/build-mac-arm64.sh, Apple Silicon) (push) Has been cancelled
Build RPCS3 / RPCS3 Windows (push) Has been cancelled
Build RPCS3 / RPCS3 Windows Clang (win64, clang, clang64) (push) Has been cancelled
Build RPCS3 / RPCS3 FreeBSD (push) Has been cancelled
Some checks failed
Generate Translation Template / Generate Translation Template (push) Has been cancelled
Build RPCS3 / RPCS3 Linux ${{ matrix.os }} ${{ matrix.compiler }} (/rpcs3/.ci/build-linux-aarch64.sh, gcc, rpcs3/rpcs3-ci-jammy-aarch64:1.6, ubuntu-24.04-arm) (push) Has been cancelled
Build RPCS3 / RPCS3 Linux ${{ matrix.os }} ${{ matrix.compiler }} (/rpcs3/.ci/build-linux.sh, gcc, rpcs3/rpcs3-ci-jammy:1.6, ubuntu-24.04) (push) Has been cancelled
Build RPCS3 / RPCS3 Linux ${{ matrix.os }} ${{ matrix.compiler }} (a1d35836e8d45bfc6f63c26f0a3e5d46ef622fe1, rpcs3/rpcs3-binaries-linux-arm64, /rpcs3/.ci/build-linux-aarch64.sh, clang, rpcs3/rpcs3-ci-jammy-aarch64:1.6, ubuntu-24.04-arm) (push) Has been cancelled
Build RPCS3 / RPCS3 Linux ${{ matrix.os }} ${{ matrix.compiler }} (d812f1254a1157c80fd402f94446310560f54e5f, rpcs3/rpcs3-binaries-linux, /rpcs3/.ci/build-linux.sh, clang, rpcs3/rpcs3-ci-jammy:1.6, ubuntu-24.04) (push) Has been cancelled
Build RPCS3 / RPCS3 Mac ${{ matrix.name }} (51ae32f468089a8169aaf1567de355ff4a3e0842, rpcs3/rpcs3-binaries-mac, arch -X86_64 .ci/build-mac.sh, Intel) (push) Has been cancelled
Build RPCS3 / RPCS3 Mac ${{ matrix.name }} (8e21bdbc40711a3fccd18fbf17b742348b0f4281, rpcs3/rpcs3-binaries-mac-arm64, .ci/build-mac-arm64.sh, Apple Silicon) (push) Has been cancelled
Build RPCS3 / RPCS3 Windows (push) Has been cancelled
Build RPCS3 / RPCS3 Windows Clang (win64, clang, clang64) (push) Has been cancelled
Build RPCS3 / RPCS3 FreeBSD (push) Has been cancelled
This commit is contained in:
parent
d087c86243
commit
d72f95677e
|
|
@ -195,14 +195,9 @@ bool Pad::get_pressure_intensity_button_active(bool is_toggle_mode, u32 player_i
|
|||
if (g_cfg.misc.show_pressure_intensity_toggle_hint)
|
||||
{
|
||||
const std::string player_id_string = std::to_string(player_id + 1);
|
||||
if (m_pressure_intensity_toggled)
|
||||
{
|
||||
rsx::overlays::queue_message(get_localized_string(localized_string_id::RSX_OVERLAYS_PRESSURE_INTENSITY_TOGGLED_ON, player_id_string.c_str()), 3'000'000);
|
||||
}
|
||||
else
|
||||
{
|
||||
rsx::overlays::queue_message(get_localized_string(localized_string_id::RSX_OVERLAYS_PRESSURE_INTENSITY_TOGGLED_OFF, player_id_string.c_str()), 3'000'000);
|
||||
}
|
||||
rsx::overlays::queue_message(get_localized_string(
|
||||
m_pressure_intensity_toggled ? localized_string_id::RSX_OVERLAYS_PRESSURE_INTENSITY_TOGGLED_ON : localized_string_id::RSX_OVERLAYS_PRESSURE_INTENSITY_TOGGLED_OFF,
|
||||
player_id_string.c_str()), 3'000'000);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -235,14 +230,9 @@ bool Pad::get_analog_limiter_button_active(bool is_toggle_mode, u32 player_id)
|
|||
if (g_cfg.misc.show_analog_limiter_toggle_hint)
|
||||
{
|
||||
const std::string player_id_string = std::to_string(player_id + 1);
|
||||
if (m_analog_limiter_toggled)
|
||||
{
|
||||
rsx::overlays::queue_message(get_localized_string(localized_string_id::RSX_OVERLAYS_ANALOG_LIMITER_TOGGLED_ON, player_id_string.c_str()), 3'000'000);
|
||||
}
|
||||
else
|
||||
{
|
||||
rsx::overlays::queue_message(get_localized_string(localized_string_id::RSX_OVERLAYS_ANALOG_LIMITER_TOGGLED_OFF, player_id_string.c_str()), 3'000'000);
|
||||
}
|
||||
rsx::overlays::queue_message(get_localized_string(
|
||||
m_analog_limiter_toggled ? localized_string_id::RSX_OVERLAYS_ANALOG_LIMITER_TOGGLED_ON : localized_string_id::RSX_OVERLAYS_ANALOG_LIMITER_TOGGLED_OFF,
|
||||
player_id_string.c_str()), 3'000'000);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -353,6 +353,7 @@ struct cfg_root : cfg::node
|
|||
cfg::_bool show_pressure_intensity_toggle_hint{ this, "Show pressure intensity toggle hint", true, true };
|
||||
cfg::_bool show_analog_limiter_toggle_hint{ this, "Show analog limiter toggle hint", true, true };
|
||||
cfg::_bool show_mouse_and_keyboard_toggle_hint{ this, "Show mouse and keyboard toggle hint", true, true };
|
||||
cfg::_bool show_capture_hints{ this, "Show capture hints", true, true };
|
||||
cfg::_bool use_native_interface{ this, "Use native user interface", true };
|
||||
cfg::string gdb_server{ this, "GDB Server", "127.0.0.1:2345" };
|
||||
cfg::_bool silence_all_logs{ this, "Silence All Logs", false, true };
|
||||
|
|
|
|||
|
|
@ -184,6 +184,7 @@ enum class emu_settings_type
|
|||
ShowPressureIntensityToggleHint,
|
||||
ShowAnalogLimiterToggleHint,
|
||||
ShowMouseAndKeyboardToggleHint,
|
||||
ShowCaptureHints,
|
||||
WindowTitleFormat,
|
||||
PauseDuringHomeMenu,
|
||||
EnableGamemode,
|
||||
|
|
@ -386,10 +387,11 @@ inline static const std::map<emu_settings_type, cfg_location> settings_location
|
|||
{ emu_settings_type::ShowPressureIntensityToggleHint, { "Miscellaneous", "Show pressure intensity toggle hint"}},
|
||||
{ emu_settings_type::ShowAnalogLimiterToggleHint, { "Miscellaneous", "Show analog limiter toggle hint"}},
|
||||
{ emu_settings_type::ShowMouseAndKeyboardToggleHint, { "Miscellaneous", "Show mouse and keyboard toggle hint"}},
|
||||
{ emu_settings_type::ShowCaptureHints, { "Miscellaneous", "Show capture hints" }},
|
||||
{ emu_settings_type::SilenceAllLogs, { "Miscellaneous", "Silence All Logs" }},
|
||||
{ emu_settings_type::WindowTitleFormat, { "Miscellaneous", "Window Title Format" }},
|
||||
{ emu_settings_type::PauseDuringHomeMenu, { "Miscellaneous", "Pause Emulation During Home Menu" }},
|
||||
{ emu_settings_type::EnableGamemode, { "Miscellaneous", "Enable GameMode" }},
|
||||
{ emu_settings_type::EnableGamemode, { "Miscellaneous", "Enable GameMode" }},
|
||||
|
||||
// Networking
|
||||
{ emu_settings_type::InternetStatus, { "Net", "Internet enabled"}},
|
||||
|
|
|
|||
|
|
@ -434,9 +434,12 @@ void gs_frame::toggle_recording()
|
|||
QApplication::beep();
|
||||
}
|
||||
|
||||
ensure(m_video_encoder->path().starts_with(fs::get_config_dir()));
|
||||
const std::string shortpath = m_video_encoder->path().substr(fs::get_config_dir().size() - 1); // -1 for /
|
||||
rsx::overlays::queue_message(tr("Recording saved: %0").arg(QString::fromStdString(shortpath)).toStdString());
|
||||
if (g_cfg.misc.show_capture_hints)
|
||||
{
|
||||
ensure(m_video_encoder->path().starts_with(fs::get_config_dir()));
|
||||
const std::string shortpath = m_video_encoder->path().substr(fs::get_config_dir().size() - 1); // -1 for /
|
||||
rsx::overlays::queue_message(tr("Recording saved: %0").arg(QString::fromStdString(shortpath)).toStdString());
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
@ -508,7 +511,11 @@ void gs_frame::toggle_recording()
|
|||
|
||||
if (m_video_encoder->has_error)
|
||||
{
|
||||
rsx::overlays::queue_message(tr("Recording not possible").toStdString());
|
||||
if (g_cfg.misc.show_capture_hints)
|
||||
{
|
||||
rsx::overlays::queue_message(tr("Recording not possible").toStdString());
|
||||
}
|
||||
|
||||
m_video_encoder->stop();
|
||||
return;
|
||||
}
|
||||
|
|
@ -516,7 +523,12 @@ void gs_frame::toggle_recording()
|
|||
if (!video_provider.set_video_sink(m_video_encoder, recording_mode::rpcs3))
|
||||
{
|
||||
gui_log.warning("The video provider could not set the video sink. A sink with higher priority must have been set.");
|
||||
rsx::overlays::queue_message(tr("Recording not possible").toStdString());
|
||||
|
||||
if (g_cfg.misc.show_capture_hints)
|
||||
{
|
||||
rsx::overlays::queue_message(tr("Recording not possible").toStdString());
|
||||
}
|
||||
|
||||
m_video_encoder->stop();
|
||||
return;
|
||||
}
|
||||
|
|
@ -525,7 +537,10 @@ void gs_frame::toggle_recording()
|
|||
|
||||
g_recording_mode = recording_mode::rpcs3;
|
||||
|
||||
rsx::overlays::queue_message(tr("Recording started").toStdString());
|
||||
if (g_cfg.misc.show_capture_hints)
|
||||
{
|
||||
rsx::overlays::queue_message(tr("Recording started").toStdString());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -1043,9 +1058,12 @@ void gs_frame::take_screenshot(std::vector<u8>&& data, u32 sshot_width, u32 ssho
|
|||
}
|
||||
});
|
||||
|
||||
ensure(filename.starts_with(fs::get_config_dir()));
|
||||
const std::string shortpath = filename.substr(fs::get_config_dir().size() - 1); // -1 for /
|
||||
rsx::overlays::queue_message(tr("Screenshot saved: %0").arg(QString::fromStdString(shortpath)).toStdString());
|
||||
if (g_cfg.misc.show_capture_hints)
|
||||
{
|
||||
ensure(filename.starts_with(fs::get_config_dir()));
|
||||
const std::string shortpath = filename.substr(fs::get_config_dir().size() - 1); // -1 for /
|
||||
rsx::overlays::queue_message(tr("Screenshot saved: %0").arg(QString::fromStdString(shortpath)).toStdString());
|
||||
}
|
||||
|
||||
return;
|
||||
},
|
||||
|
|
|
|||
|
|
@ -1873,6 +1873,9 @@ settings_dialog::settings_dialog(std::shared_ptr<gui_settings> gui_settings, std
|
|||
m_emu_settings->EnhanceCheckBox(ui->showMouseAndKeyboardToggleHint, emu_settings_type::ShowMouseAndKeyboardToggleHint);
|
||||
SubscribeTooltip(ui->showMouseAndKeyboardToggleHint, tooltips.settings.show_mouse_and_keyboard_toggle_hint);
|
||||
|
||||
m_emu_settings->EnhanceCheckBox(ui->showCaptureHints, emu_settings_type::ShowCaptureHints);
|
||||
SubscribeTooltip(ui->showCaptureHints, tooltips.settings.show_capture_hints);
|
||||
|
||||
m_emu_settings->EnhanceCheckBox(ui->pauseDuringHomeMenu, emu_settings_type::PauseDuringHomeMenu);
|
||||
SubscribeTooltip(ui->pauseDuringHomeMenu, tooltips.settings.pause_during_home_menu);
|
||||
|
||||
|
|
|
|||
|
|
@ -3008,6 +3008,13 @@
|
|||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="showCaptureHints">
|
||||
<property name="text">
|
||||
<string>Show capture hints</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="startGameFullscreen">
|
||||
<property name="text">
|
||||
|
|
@ -3028,7 +3035,7 @@
|
|||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="visible">
|
||||
<bool>false</bool>
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Enable GameMode</string>
|
||||
|
|
|
|||
|
|
@ -151,6 +151,7 @@ public:
|
|||
const QString show_pressure_intensity_toggle_hint = tr("Shows pressure intensity toggle hint using the native overlay.");
|
||||
const QString show_analog_limiter_toggle_hint = tr("Shows analog limiter toggle hint using the native overlay.");
|
||||
const QString show_mouse_and_keyboard_toggle_hint = tr("Shows mouse and keyboard toggle hint using the native overlay.");
|
||||
const QString show_capture_hints = tr("Shows screenshot and recording hints using the native overlay.");
|
||||
const QString use_native_interface = tr("Enables use of native HUD within the game window that can interact with game controllers.\nWhen disabled, regular Qt dialogs are used instead.\nCurrently, the on-screen keyboard only supports the English key layout.");
|
||||
const QString pause_during_home_menu = tr("When enabled, opening the home menu will also pause emulation.\nWhile most games pause themselves while the home menu is shown, some do not.\nIn that case it can be helpful to pause the emulation whenever the home menu is open.");
|
||||
|
||||
|
|
|
|||
|
|
@ -2,6 +2,7 @@
|
|||
#include "video_provider.h"
|
||||
#include "Emu/RSX/Overlays/overlay_message.h"
|
||||
#include "Emu/Cell/timers.hpp"
|
||||
#include "Emu/system_config.h"
|
||||
|
||||
extern "C"
|
||||
{
|
||||
|
|
@ -89,7 +90,11 @@ namespace utils
|
|||
if (!m_video_sink || m_video_sink->has_error)
|
||||
{
|
||||
g_recording_mode = recording_mode::stopped;
|
||||
rsx::overlays::queue_message(localized_string_id::RECORDING_ABORTED);
|
||||
|
||||
if (g_cfg.misc.show_capture_hints)
|
||||
{
|
||||
rsx::overlays::queue_message(localized_string_id::RECORDING_ABORTED);
|
||||
}
|
||||
}
|
||||
|
||||
if (g_recording_mode == recording_mode::stopped)
|
||||
|
|
|
|||
Loading…
Reference in a new issue