From c7080e5d99bf77e432e6c900e64489b78a233f28 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Sun, 30 Mar 2025 22:30:47 +0200 Subject: Revert "Add high performance encoding option (for amd) in settings page. Requires gsr version >= 5.3.4" This reverts commit 3060e3ee000ddb12a78d8008f641b724ce7b07df. --- src/Config.cpp | 1 - src/GsrInfo.cpp | 2 +- src/Overlay.cpp | 7 +------ src/gui/GlobalSettingsPage.cpp | 22 +++------------------- 4 files changed, 5 insertions(+), 27 deletions(-) (limited to 'src') diff --git a/src/Config.cpp b/src/Config.cpp index c22bde3..fdb5e4a 100644 --- a/src/Config.cpp +++ b/src/Config.cpp @@ -158,7 +158,6 @@ namespace gsr { return { {"main.config_file_version", &config.main_config.config_file_version}, {"main.software_encoding_warning_shown", &config.main_config.software_encoding_warning_shown}, - {"main.high_performance_encoding", &config.main_config.high_performance_encoding}, {"main.hotkeys_enable_option", &config.main_config.hotkeys_enable_option}, {"main.joystick_hotkeys_enable_option", &config.main_config.joystick_hotkeys_enable_option}, {"main.tint_color", &config.main_config.tint_color}, diff --git a/src/GsrInfo.cpp b/src/GsrInfo.cpp index 5af6397..5f8e00d 100644 --- a/src/GsrInfo.cpp +++ b/src/GsrInfo.cpp @@ -11,7 +11,7 @@ namespace gsr { } bool GsrVersion::operator>=(const GsrVersion &other) const { - return major > other.major || (major == other.major && minor > other.minor) || (major == other.major && minor == other.minor && patch >= other.patch); + return major >= other.major || (major == other.major && minor >= other.minor) || (major == other.major && minor == other.minor && patch >= other.patch); } bool GsrVersion::operator<(const GsrVersion &other) const { diff --git a/src/Overlay.cpp b/src/Overlay.cpp index 6e5f8e4..4eb8844 100644 --- a/src/Overlay.cpp +++ b/src/Overlay.cpp @@ -1841,7 +1841,7 @@ namespace gsr { args.push_back(region_str); } - void Overlay::add_common_gpu_screen_recorder_args(std::vector &args, const RecordOptions &record_options, const std::vector &audio_tracks, const std::string &video_bitrate, const char *region, const std::string &audio_devices_merged, char *region_str, int region_str_size, const RegionSelector ®ion_selector) { + static void add_common_gpu_screen_recorder_args(std::vector &args, const RecordOptions &record_options, const std::vector &audio_tracks, const std::string &video_bitrate, const char *region, const std::string &audio_devices_merged, char *region_str, int region_str_size, const RegionSelector ®ion_selector) { if(record_options.video_quality == "custom") { args.push_back("-bm"); args.push_back("cbr"); @@ -1876,11 +1876,6 @@ namespace gsr { if(record_options.record_area_option == "region") add_region_command(args, region_str, region_str_size, region_selector); - - if(config.main_config.high_performance_encoding && gsr_info.gpu_info.vendor != GpuVendor::NVIDIA && gsr_info.system_info.gsr_version >= GsrVersion{5, 3, 4}) { - args.push_back("-high-performance-encoding"); - args.push_back("yes"); - } } static bool validate_capture_target(const GsrInfo &gsr_info, const std::string &capture_target) { diff --git a/src/gui/GlobalSettingsPage.cpp b/src/gui/GlobalSettingsPage.cpp index c80320f..6162ec6 100644 --- a/src/gui/GlobalSettingsPage.cpp +++ b/src/gui/GlobalSettingsPage.cpp @@ -14,7 +14,6 @@ #include "../../include/gui/RadioButton.hpp" #include "../../include/gui/LineSeparator.hpp" #include "../../include/gui/CustomRendererWidget.hpp" -#include "../../include/gui/CheckBox.hpp" #include #include @@ -399,13 +398,6 @@ namespace gsr { return subsection; } - std::unique_ptr GlobalSettingsPage::create_high_performance_encoding_option() { - auto checkbox = std::make_unique(&get_theme().body_font, "High performance encoding mode (Experimental, may cause performance issues)"); - high_performance_encoding_checkbox_ptr = checkbox.get(); - checkbox->set_visible(gsr_info->gpu_info.vendor != GpuVendor::NVIDIA && gsr_info->system_info.gsr_version >= GsrVersion{5, 3, 4}); - return checkbox; - } - std::unique_ptr