|
|
|
@ -55,20 +55,20 @@ static constexpr VkPresentModeKHR VSyncSettingToMode(Settings::VSyncMode mode) { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// static constexpr Settings::VSyncMode PresentModeToSetting(VkPresentModeKHR mode) {
|
|
|
|
// switch (mode) {
|
|
|
|
// case VK_PRESENT_MODE_IMMEDIATE_KHR:
|
|
|
|
// return Settings::VSyncMode::Immediate;
|
|
|
|
// case VK_PRESENT_MODE_MAILBOX_KHR:
|
|
|
|
// return Settings::VSyncMode::Mailbox;
|
|
|
|
// case VK_PRESENT_MODE_FIFO_KHR:
|
|
|
|
// return Settings::VSyncMode::FIFO;
|
|
|
|
// case VK_PRESENT_MODE_FIFO_RELAXED_KHR:
|
|
|
|
// return Settings::VSyncMode::FIFORelaxed;
|
|
|
|
// default:
|
|
|
|
// return Settings::VSyncMode::FIFO;
|
|
|
|
// }
|
|
|
|
// }
|
|
|
|
static constexpr Settings::VSyncMode PresentModeToSetting(VkPresentModeKHR mode) { |
|
|
|
switch (mode) { |
|
|
|
case VK_PRESENT_MODE_IMMEDIATE_KHR: |
|
|
|
return Settings::VSyncMode::Immediate; |
|
|
|
case VK_PRESENT_MODE_MAILBOX_KHR: |
|
|
|
return Settings::VSyncMode::Mailbox; |
|
|
|
case VK_PRESENT_MODE_FIFO_KHR: |
|
|
|
return Settings::VSyncMode::FIFO; |
|
|
|
case VK_PRESENT_MODE_FIFO_RELAXED_KHR: |
|
|
|
return Settings::VSyncMode::FIFORelaxed; |
|
|
|
default: |
|
|
|
return Settings::VSyncMode::FIFO; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
ConfigureGraphics::ConfigureGraphics( |
|
|
|
const Core::System& system_, std::vector<VkDeviceInfo::Record>& records_, |
|
|
|
@ -112,16 +112,9 @@ ConfigureGraphics::ConfigureGraphics( |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
SetupPerGameUI(); |
|
|
|
|
|
|
|
connect(api_combobox, qOverload<int>(&QComboBox::currentIndexChanged), this, [this] { |
|
|
|
UpdateAPILayout(); |
|
|
|
PopulateVSyncModeSelection(); |
|
|
|
if (!Settings::IsConfiguringGlobal()) { |
|
|
|
ConfigurationShared::SetHighlight(ui->api_widget, |
|
|
|
api_combobox->currentIndex() != |
|
|
|
ConfigurationShared::USE_GLOBAL_INDEX); |
|
|
|
} |
|
|
|
}); |
|
|
|
connect(vulkan_device_combobox, qOverload<int>(&QComboBox::activated), this, |
|
|
|
[this](int device) { |
|
|
|
@ -215,18 +208,22 @@ void ConfigureGraphics::SetConfiguration() { |
|
|
|
QLayout& graphics_layout = *ui->graphics_widget->layout(); |
|
|
|
|
|
|
|
std::map<bool, std::map<std::string, QWidget*>> hold_graphics; |
|
|
|
std::forward_list<QWidget*> hold_api; |
|
|
|
|
|
|
|
for (const auto setting : Settings::values.linkage.by_category[Settings::Category::Renderer]) { |
|
|
|
const auto& setting_label = setting->GetLabel(); |
|
|
|
|
|
|
|
auto [widget, extra] = [&]() { |
|
|
|
if (setting->Id() == Settings::values.vulkan_device.Id()) { |
|
|
|
if (setting->Id() == Settings::values.vulkan_device.Id() || |
|
|
|
setting->Id() == Settings::values.shader_backend.Id() || |
|
|
|
setting->Id() == Settings::values.vsync_mode.Id()) { |
|
|
|
return ConfigurationShared::CreateWidget( |
|
|
|
setting, translations, this, runtime_lock, apply_funcs, trackers, |
|
|
|
ConfigurationShared::RequestType::ComboBox); |
|
|
|
ConfigurationShared::RequestType::ComboBox, false); |
|
|
|
} else { |
|
|
|
return ConfigurationShared::CreateWidget(setting, translations, this, runtime_lock, |
|
|
|
apply_funcs, trackers); |
|
|
|
} |
|
|
|
return ConfigurationShared::CreateWidget(setting, translations, this, runtime_lock, |
|
|
|
apply_funcs, trackers); |
|
|
|
}(); |
|
|
|
|
|
|
|
if (widget == nullptr) { |
|
|
|
@ -237,11 +234,11 @@ void ConfigureGraphics::SetConfiguration() { |
|
|
|
api_layout.addWidget(widget); |
|
|
|
api_combobox = reinterpret_cast<QComboBox*>(extra); |
|
|
|
} else if (setting->Id() == Settings::values.vulkan_device.Id()) { |
|
|
|
api_layout.addWidget(widget); |
|
|
|
hold_api.push_front(widget); |
|
|
|
vulkan_device_combobox = reinterpret_cast<QComboBox*>(extra); |
|
|
|
vulkan_device_widget = widget; |
|
|
|
} else if (setting->Id() == Settings::values.shader_backend.Id()) { |
|
|
|
api_layout.addWidget(widget); |
|
|
|
hold_api.push_front(widget); |
|
|
|
shader_backend_combobox = reinterpret_cast<QComboBox*>(extra); |
|
|
|
shader_backend_widget = widget; |
|
|
|
} else if (setting->Id() == Settings::values.vsync_mode.Id()) { |
|
|
|
@ -258,86 +255,9 @@ void ConfigureGraphics::SetConfiguration() { |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
// ui->api_widget->setEnabled(runtime_lock);
|
|
|
|
// ui->use_asynchronous_gpu_emulation->setEnabled(runtime_lock);
|
|
|
|
// ui->use_disk_shader_cache->setEnabled(runtime_lock);
|
|
|
|
// ui->nvdec_emulation_widget->setEnabled(runtime_lock);
|
|
|
|
// ui->resolution_combobox->setEnabled(runtime_lock);
|
|
|
|
// ui->astc_decode_mode_combobox->setEnabled(runtime_lock);
|
|
|
|
// ui->vsync_mode_layout->setEnabled(runtime_lock ||
|
|
|
|
// Settings::values.renderer_backend.GetValue() ==
|
|
|
|
// Settings::RendererBackend::Vulkan);
|
|
|
|
// ui->use_disk_shader_cache->setChecked(Settings::values.use_disk_shader_cache.GetValue());
|
|
|
|
// ui->use_asynchronous_gpu_emulation->setChecked(
|
|
|
|
// Settings::values.use_asynchronous_gpu_emulation.GetValue());
|
|
|
|
|
|
|
|
// if (Settings::IsConfiguringGlobal()) {
|
|
|
|
// api_combobox->setCurrentIndex(static_cast<int>(Settings::values.renderer_backend.GetValue()));
|
|
|
|
// ui->fullscreen_mode_combobox->setCurrentIndex(
|
|
|
|
// static_cast<int>(Settings::values.fullscreen_mode.GetValue()));
|
|
|
|
// ui->nvdec_emulation->setCurrentIndex(
|
|
|
|
// static_cast<int>(Settings::values.nvdec_emulation.GetValue()));
|
|
|
|
// ui->aspect_ratio_combobox->setCurrentIndex(Settings::values.aspect_ratio.GetValue());
|
|
|
|
// ui->resolution_combobox->setCurrentIndex(
|
|
|
|
// static_cast<int>(Settings::values.resolution_setup.GetValue()));
|
|
|
|
// ui->scaling_filter_combobox->setCurrentIndex(
|
|
|
|
// static_cast<int>(Settings::values.scaling_filter.GetValue()));
|
|
|
|
// ui->fsr_sharpening_slider->setValue(Settings::values.fsr_sharpening_slider.GetValue());
|
|
|
|
// ui->anti_aliasing_combobox->setCurrentIndex(
|
|
|
|
// static_cast<int>(Settings::values.anti_aliasing.GetValue()));
|
|
|
|
// } else {
|
|
|
|
// ConfigurationShared::SetPerGameSetting(api_combobox, &Settings::values.renderer_backend);
|
|
|
|
// ConfigurationShared::SetHighlight(ui->api_widget,
|
|
|
|
// !Settings::values.renderer_backend.UsingGlobal());
|
|
|
|
|
|
|
|
// ConfigurationShared::SetPerGameSetting(ui->astc_decode_mode_combobox,
|
|
|
|
// &Settings::values.accelerate_astc);
|
|
|
|
// ConfigurationShared::SetHighlight(ui->astc_decode_mode_layout,
|
|
|
|
// !Settings::values.accelerate_astc.UsingGlobal());
|
|
|
|
|
|
|
|
// ConfigurationShared::SetPerGameSetting(ui->nvdec_emulation,
|
|
|
|
// &Settings::values.nvdec_emulation);
|
|
|
|
// ConfigurationShared::SetHighlight(ui->nvdec_emulation_widget,
|
|
|
|
// !Settings::values.nvdec_emulation.UsingGlobal());
|
|
|
|
|
|
|
|
// ConfigurationShared::SetPerGameSetting(ui->fullscreen_mode_combobox,
|
|
|
|
// &Settings::values.fullscreen_mode);
|
|
|
|
// ConfigurationShared::SetHighlight(ui->fullscreen_mode_label,
|
|
|
|
// !Settings::values.fullscreen_mode.UsingGlobal());
|
|
|
|
|
|
|
|
// ConfigurationShared::SetPerGameSetting(ui->aspect_ratio_combobox,
|
|
|
|
// &Settings::values.aspect_ratio);
|
|
|
|
// ConfigurationShared::SetHighlight(ui->ar_label,
|
|
|
|
// !Settings::values.aspect_ratio.UsingGlobal());
|
|
|
|
|
|
|
|
// ConfigurationShared::SetPerGameSetting(ui->resolution_combobox,
|
|
|
|
// &Settings::values.resolution_setup);
|
|
|
|
// ConfigurationShared::SetHighlight(ui->resolution_label,
|
|
|
|
// !Settings::values.resolution_setup.UsingGlobal());
|
|
|
|
|
|
|
|
// ConfigurationShared::SetPerGameSetting(ui->scaling_filter_combobox,
|
|
|
|
// &Settings::values.scaling_filter);
|
|
|
|
// ConfigurationShared::SetHighlight(ui->scaling_filter_label,
|
|
|
|
// !Settings::values.scaling_filter.UsingGlobal());
|
|
|
|
|
|
|
|
// ConfigurationShared::SetPerGameSetting(ui->anti_aliasing_combobox,
|
|
|
|
// &Settings::values.anti_aliasing);
|
|
|
|
// ConfigurationShared::SetHighlight(ui->anti_aliasing_label,
|
|
|
|
// !Settings::values.anti_aliasing.UsingGlobal());
|
|
|
|
|
|
|
|
// ui->fsr_sharpening_combobox->setCurrentIndex(
|
|
|
|
// Settings::values.fsr_sharpening_slider.UsingGlobal() ? 0 : 1);
|
|
|
|
// ui->fsr_sharpening_slider->setEnabled(
|
|
|
|
// !Settings::values.fsr_sharpening_slider.UsingGlobal());
|
|
|
|
// ui->fsr_sharpening_value->setEnabled(!Settings::values.fsr_sharpening_slider.UsingGlobal());
|
|
|
|
// ConfigurationShared::SetHighlight(ui->fsr_sharpening_layout,
|
|
|
|
// !Settings::values.fsr_sharpening_slider.UsingGlobal());
|
|
|
|
// ui->fsr_sharpening_slider->setValue(Settings::values.fsr_sharpening_slider.GetValue());
|
|
|
|
|
|
|
|
// ui->bg_combobox->setCurrentIndex(Settings::values.bg_red.UsingGlobal() ? 0 : 1);
|
|
|
|
// ui->bg_button->setEnabled(!Settings::values.bg_red.UsingGlobal());
|
|
|
|
// ConfigurationShared::SetHighlight(ui->bg_layout, !Settings::values.bg_red.UsingGlobal());
|
|
|
|
// }
|
|
|
|
for (auto widget : hold_api) { |
|
|
|
api_layout.addWidget(widget); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
void ConfigureGraphics::SetFSRIndicatorText(int percentage) { |
|
|
|
@ -367,134 +287,16 @@ const QString ConfigureGraphics::TranslateVSyncMode(VkPresentModeKHR mode, |
|
|
|
} |
|
|
|
|
|
|
|
void ConfigureGraphics::ApplyConfiguration() { |
|
|
|
// const auto resolution_setup = static_cast<Settings::ResolutionSetup>(
|
|
|
|
// ui->resolution_combobox->currentIndex() -
|
|
|
|
// ((Settings::IsConfiguringGlobal()) ? 0 : ConfigurationShared::USE_GLOBAL_OFFSET));
|
|
|
|
|
|
|
|
// const auto scaling_filter = static_cast<Settings::ScalingFilter>(
|
|
|
|
// ui->scaling_filter_combobox->currentIndex() -
|
|
|
|
// ((Settings::IsConfiguringGlobal()) ? 0 : ConfigurationShared::USE_GLOBAL_OFFSET));
|
|
|
|
|
|
|
|
// const auto anti_aliasing = static_cast<Settings::AntiAliasing>(
|
|
|
|
// ui->anti_aliasing_combobox->currentIndex() -
|
|
|
|
// ((Settings::IsConfiguringGlobal()) ? 0 : ConfigurationShared::USE_GLOBAL_OFFSET));
|
|
|
|
|
|
|
|
// ConfigurationShared::ApplyPerGameSetting(&Settings::values.fullscreen_mode,
|
|
|
|
// ui->fullscreen_mode_combobox);
|
|
|
|
// ConfigurationShared::ApplyPerGameSetting(&Settings::values.aspect_ratio,
|
|
|
|
// ui->aspect_ratio_combobox);
|
|
|
|
// ConfigurationShared::ApplyPerGameSetting(&Settings::values.use_disk_shader_cache,
|
|
|
|
// ui->use_disk_shader_cache, use_disk_shader_cache);
|
|
|
|
// ConfigurationShared::ApplyPerGameSetting(&Settings::values.use_asynchronous_gpu_emulation,
|
|
|
|
// ui->use_asynchronous_gpu_emulation,
|
|
|
|
// use_asynchronous_gpu_emulation);
|
|
|
|
// ConfigurationShared::ApplyPerGameSetting(&Settings::values.accelerate_astc,
|
|
|
|
// ui->astc_decode_mode_combobox);
|
|
|
|
|
|
|
|
// if (Settings::IsConfiguringGlobal()) {
|
|
|
|
// // Guard if during game and set to game-specific value
|
|
|
|
// if (Settings::values.renderer_backend.UsingGlobal()) {
|
|
|
|
// Settings::values.renderer_backend.SetValue(GetCurrentGraphicsBackend());
|
|
|
|
// }
|
|
|
|
// if (Settings::values.nvdec_emulation.UsingGlobal()) {
|
|
|
|
// Settings::values.nvdec_emulation.SetValue(GetCurrentNvdecEmulation());
|
|
|
|
// }
|
|
|
|
// if (Settings::values.shader_backend.UsingGlobal()) {
|
|
|
|
// Settings::values.shader_backend.SetValue(shader_backend);
|
|
|
|
// }
|
|
|
|
// if (Settings::values.vulkan_device.UsingGlobal()) {
|
|
|
|
// Settings::values.vulkan_device.SetValue(vulkan_device);
|
|
|
|
// }
|
|
|
|
// if (Settings::values.bg_red.UsingGlobal()) {
|
|
|
|
// Settings::values.bg_red.SetValue(static_cast<u8>(bg_color.red()));
|
|
|
|
// Settings::values.bg_green.SetValue(static_cast<u8>(bg_color.green()));
|
|
|
|
// Settings::values.bg_blue.SetValue(static_cast<u8>(bg_color.blue()));
|
|
|
|
// }
|
|
|
|
// if (Settings::values.resolution_setup.UsingGlobal()) {
|
|
|
|
// Settings::values.resolution_setup.SetValue(resolution_setup);
|
|
|
|
// }
|
|
|
|
// if (Settings::values.scaling_filter.UsingGlobal()) {
|
|
|
|
// Settings::values.scaling_filter.SetValue(scaling_filter);
|
|
|
|
// }
|
|
|
|
// if (Settings::values.anti_aliasing.UsingGlobal()) {
|
|
|
|
// Settings::values.anti_aliasing.SetValue(anti_aliasing);
|
|
|
|
// }
|
|
|
|
// Settings::values.fsr_sharpening_slider.SetValue(ui->fsr_sharpening_slider->value());
|
|
|
|
|
|
|
|
// const auto mode = vsync_mode_combobox_enum_map[vsync_mode_combobox->currentIndex()];
|
|
|
|
// const auto vsync_mode = PresentModeToSetting(mode);
|
|
|
|
// Settings::values.vsync_mode.SetValue(vsync_mode);
|
|
|
|
// } else {
|
|
|
|
// if (ui->resolution_combobox->currentIndex() == ConfigurationShared::USE_GLOBAL_INDEX) {
|
|
|
|
// Settings::values.resolution_setup.SetGlobal(true);
|
|
|
|
// } else {
|
|
|
|
// Settings::values.resolution_setup.SetGlobal(false);
|
|
|
|
// Settings::values.resolution_setup.SetValue(resolution_setup);
|
|
|
|
// }
|
|
|
|
// if (ui->scaling_filter_combobox->currentIndex() == ConfigurationShared::USE_GLOBAL_INDEX)
|
|
|
|
// {
|
|
|
|
// Settings::values.scaling_filter.SetGlobal(true);
|
|
|
|
// } else {
|
|
|
|
// Settings::values.scaling_filter.SetGlobal(false);
|
|
|
|
// Settings::values.scaling_filter.SetValue(scaling_filter);
|
|
|
|
// }
|
|
|
|
// if (ui->anti_aliasing_combobox->currentIndex() == ConfigurationShared::USE_GLOBAL_INDEX)
|
|
|
|
// {
|
|
|
|
// Settings::values.anti_aliasing.SetGlobal(true);
|
|
|
|
// } else {
|
|
|
|
// Settings::values.anti_aliasing.SetGlobal(false);
|
|
|
|
// Settings::values.anti_aliasing.SetValue(anti_aliasing);
|
|
|
|
// }
|
|
|
|
// if (api_combobox->currentIndex() == ConfigurationShared::USE_GLOBAL_INDEX) {
|
|
|
|
// Settings::values.renderer_backend.SetGlobal(true);
|
|
|
|
// Settings::values.shader_backend.SetGlobal(true);
|
|
|
|
// Settings::values.vulkan_device.SetGlobal(true);
|
|
|
|
// } else {
|
|
|
|
// Settings::values.renderer_backend.SetGlobal(false);
|
|
|
|
// Settings::values.renderer_backend.SetValue(GetCurrentGraphicsBackend());
|
|
|
|
// switch (GetCurrentGraphicsBackend()) {
|
|
|
|
// case Settings::RendererBackend::OpenGL:
|
|
|
|
// case Settings::RendererBackend::Null:
|
|
|
|
// Settings::values.shader_backend.SetGlobal(false);
|
|
|
|
// Settings::values.vulkan_device.SetGlobal(true);
|
|
|
|
// Settings::values.shader_backend.SetValue(shader_backend);
|
|
|
|
// break;
|
|
|
|
// case Settings::RendererBackend::Vulkan:
|
|
|
|
// Settings::values.shader_backend.SetGlobal(true);
|
|
|
|
// Settings::values.vulkan_device.SetGlobal(false);
|
|
|
|
// Settings::values.vulkan_device.SetValue(vulkan_device);
|
|
|
|
// break;
|
|
|
|
// }
|
|
|
|
// }
|
|
|
|
|
|
|
|
// if (ui->nvdec_emulation->currentIndex() == ConfigurationShared::USE_GLOBAL_INDEX) {
|
|
|
|
// Settings::values.nvdec_emulation.SetGlobal(true);
|
|
|
|
// } else {
|
|
|
|
// Settings::values.nvdec_emulation.SetGlobal(false);
|
|
|
|
// Settings::values.nvdec_emulation.SetValue(GetCurrentNvdecEmulation());
|
|
|
|
// }
|
|
|
|
|
|
|
|
// if (ui->bg_combobox->currentIndex() == ConfigurationShared::USE_GLOBAL_INDEX) {
|
|
|
|
// Settings::values.bg_red.SetGlobal(true);
|
|
|
|
// Settings::values.bg_green.SetGlobal(true);
|
|
|
|
// Settings::values.bg_blue.SetGlobal(true);
|
|
|
|
// } else {
|
|
|
|
// Settings::values.bg_red.SetGlobal(false);
|
|
|
|
// Settings::values.bg_green.SetGlobal(false);
|
|
|
|
// Settings::values.bg_blue.SetGlobal(false);
|
|
|
|
// Settings::values.bg_red.SetValue(static_cast<u8>(bg_color.red()));
|
|
|
|
// Settings::values.bg_green.SetValue(static_cast<u8>(bg_color.green()));
|
|
|
|
// Settings::values.bg_blue.SetValue(static_cast<u8>(bg_color.blue()));
|
|
|
|
// }
|
|
|
|
const bool powered_on = system.IsPoweredOn(); |
|
|
|
for (const auto& func : apply_funcs) { |
|
|
|
func(powered_on); |
|
|
|
} |
|
|
|
|
|
|
|
// if (ui->fsr_sharpening_combobox->currentIndex() == ConfigurationShared::USE_GLOBAL_INDEX)
|
|
|
|
// {
|
|
|
|
// Settings::values.fsr_sharpening_slider.SetGlobal(true);
|
|
|
|
// } else {
|
|
|
|
// Settings::values.fsr_sharpening_slider.SetGlobal(false);
|
|
|
|
// Settings::values.fsr_sharpening_slider.SetValue(ui->fsr_sharpening_slider->value());
|
|
|
|
// }
|
|
|
|
// }
|
|
|
|
if (Settings::IsConfiguringGlobal()) { |
|
|
|
const auto mode = vsync_mode_combobox_enum_map[vsync_mode_combobox->currentIndex()]; |
|
|
|
const auto vsync_mode = PresentModeToSetting(mode); |
|
|
|
Settings::values.vsync_mode.SetValue(vsync_mode); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
void ConfigureGraphics::changeEvent(QEvent* event) { |
|
|
|
@ -581,83 +383,3 @@ Settings::RendererBackend ConfigureGraphics::GetCurrentGraphicsBackend() const { |
|
|
|
return static_cast<Settings::RendererBackend>(api_combobox->currentIndex() - |
|
|
|
ConfigurationShared::USE_GLOBAL_OFFSET); |
|
|
|
} |
|
|
|
|
|
|
|
Settings::NvdecEmulation ConfigureGraphics::GetCurrentNvdecEmulation() const { |
|
|
|
return Settings::NvdecEmulation::CPU; |
|
|
|
// if (Settings::IsConfiguringGlobal()) {
|
|
|
|
// return static_cast<Settings::NvdecEmulation>(ui->nvdec_emulation->currentIndex());
|
|
|
|
// }
|
|
|
|
|
|
|
|
// if (ui->nvdec_emulation->currentIndex() == ConfigurationShared::USE_GLOBAL_INDEX) {
|
|
|
|
// Settings::values.nvdec_emulation.SetGlobal(true);
|
|
|
|
// return Settings::values.nvdec_emulation.GetValue();
|
|
|
|
// }
|
|
|
|
// Settings::values.nvdec_emulation.SetGlobal(false);
|
|
|
|
// return static_cast<Settings::NvdecEmulation>(ui->nvdec_emulation->currentIndex() -
|
|
|
|
// ConfigurationShared::USE_GLOBAL_OFFSET);
|
|
|
|
} |
|
|
|
|
|
|
|
void ConfigureGraphics::SetupPerGameUI() { |
|
|
|
// if (Settings::IsConfiguringGlobal()) {
|
|
|
|
// api_combobox->setEnabled(Settings::values.renderer_backend.UsingGlobal());
|
|
|
|
// vulkan_device_combobox->setEnabled(Settings::values.renderer_backend.UsingGlobal());
|
|
|
|
// ui->fullscreen_mode_combobox->setEnabled(Settings::values.fullscreen_mode.UsingGlobal());
|
|
|
|
// ui->aspect_ratio_combobox->setEnabled(Settings::values.aspect_ratio.UsingGlobal());
|
|
|
|
// ui->resolution_combobox->setEnabled(Settings::values.resolution_setup.UsingGlobal());
|
|
|
|
// ui->scaling_filter_combobox->setEnabled(Settings::values.scaling_filter.UsingGlobal());
|
|
|
|
// ui->fsr_sharpening_slider->setEnabled(Settings::values.fsr_sharpening_slider.UsingGlobal());
|
|
|
|
// ui->anti_aliasing_combobox->setEnabled(Settings::values.anti_aliasing.UsingGlobal());
|
|
|
|
// ui->use_asynchronous_gpu_emulation->setEnabled(
|
|
|
|
// Settings::values.use_asynchronous_gpu_emulation.UsingGlobal());
|
|
|
|
// ui->nvdec_emulation->setEnabled(Settings::values.nvdec_emulation.UsingGlobal());
|
|
|
|
// ui->astc_decode_mode_combobox->setEnabled(Settings::values.accelerate_astc.UsingGlobal());
|
|
|
|
// ui->use_disk_shader_cache->setEnabled(Settings::values.use_disk_shader_cache.UsingGlobal());
|
|
|
|
// ui->bg_button->setEnabled(Settings::values.bg_red.UsingGlobal());
|
|
|
|
// ui->fsr_slider_layout->setEnabled(Settings::values.fsr_sharpening_slider.UsingGlobal());
|
|
|
|
|
|
|
|
// return;
|
|
|
|
// }
|
|
|
|
|
|
|
|
// connect(ui->bg_combobox, qOverload<int>(&QComboBox::activated), this, [this](int index) {
|
|
|
|
// ui->bg_button->setEnabled(index == 1);
|
|
|
|
// ConfigurationShared::SetHighlight(ui->bg_layout, index == 1);
|
|
|
|
// });
|
|
|
|
|
|
|
|
// connect(ui->fsr_sharpening_combobox, qOverload<int>(&QComboBox::activated), this,
|
|
|
|
// [this](int index) {
|
|
|
|
// ui->fsr_sharpening_slider->setEnabled(index == 1);
|
|
|
|
// ui->fsr_sharpening_value->setEnabled(index == 1);
|
|
|
|
// ConfigurationShared::SetHighlight(ui->fsr_sharpening_layout, index == 1);
|
|
|
|
// });
|
|
|
|
|
|
|
|
// ConfigurationShared::SetColoredTristate(
|
|
|
|
// ui->use_disk_shader_cache, Settings::values.use_disk_shader_cache,
|
|
|
|
// use_disk_shader_cache);
|
|
|
|
// ConfigurationShared::SetColoredTristate(ui->use_asynchronous_gpu_emulation,
|
|
|
|
// Settings::values.use_asynchronous_gpu_emulation,
|
|
|
|
// use_asynchronous_gpu_emulation);
|
|
|
|
|
|
|
|
// ConfigurationShared::SetColoredComboBox(ui->aspect_ratio_combobox, ui->ar_label,
|
|
|
|
// Settings::values.aspect_ratio.GetValue(true));
|
|
|
|
// ConfigurationShared::SetColoredComboBox(
|
|
|
|
// ui->fullscreen_mode_combobox, ui->fullscreen_mode_label,
|
|
|
|
// static_cast<int>(Settings::values.fullscreen_mode.GetValue(true)));
|
|
|
|
// ConfigurationShared::SetColoredComboBox(
|
|
|
|
// ui->resolution_combobox, ui->resolution_label,
|
|
|
|
// static_cast<int>(Settings::values.resolution_setup.GetValue(true)));
|
|
|
|
// ConfigurationShared::SetColoredComboBox(
|
|
|
|
// ui->scaling_filter_combobox, ui->scaling_filter_label,
|
|
|
|
// static_cast<int>(Settings::values.scaling_filter.GetValue(true)));
|
|
|
|
// ConfigurationShared::SetColoredComboBox(
|
|
|
|
// ui->anti_aliasing_combobox, ui->anti_aliasing_label,
|
|
|
|
// static_cast<int>(Settings::values.anti_aliasing.GetValue(true)));
|
|
|
|
// ConfigurationShared::SetColoredComboBox(
|
|
|
|
// ui->astc_decode_mode_combobox, ui->astc_decode_mode_label,
|
|
|
|
// static_cast<int>(Settings::values.accelerate_astc.GetValue(true)));
|
|
|
|
// ConfigurationShared::InsertGlobalItem(
|
|
|
|
// api_combobox, static_cast<int>(Settings::values.renderer_backend.GetValue(true)));
|
|
|
|
// ConfigurationShared::InsertGlobalItem(
|
|
|
|
// ui->nvdec_emulation, static_cast<int>(Settings::values.nvdec_emulation.GetValue(true)));
|
|
|
|
|
|
|
|
// ui->vsync_mode_layout->setVisible(false);
|
|
|
|
} |