diff --git a/src/citra_qt/configuration/configure_enhancements.cpp b/src/citra_qt/configuration/configure_enhancements.cpp index 3619adb34..0914d37f4 100644 --- a/src/citra_qt/configuration/configure_enhancements.cpp +++ b/src/citra_qt/configuration/configure_enhancements.cpp @@ -42,6 +42,8 @@ ConfigureEnhancements::ConfigureEnhancements(QWidget* parent) if (!ui->toggle_preload_textures->isEnabled()) ui->toggle_preload_textures->setChecked(false); }); + + ui->toggle_disk_shader_cache->setEnabled(Settings::values.use_hw_shader); } void ConfigureEnhancements::SetConfiguration() { @@ -52,7 +54,8 @@ void ConfigureEnhancements::SetConfiguration() { ui->toggle_linear_filter->setChecked(Settings::values.filter_mode); ui->layout_combobox->setCurrentIndex(static_cast(Settings::values.layout_option)); ui->swap_screen->setChecked(Settings::values.swap_screen); - ui->toggle_disk_shader_cache->setChecked(Settings::values.use_disk_shader_cache); + ui->toggle_disk_shader_cache->setChecked(Settings::values.use_hw_shader && + Settings::values.use_disk_shader_cache); ui->upright_screen->setChecked(Settings::values.upright_screen); ui->toggle_dump_textures->setChecked(Settings::values.dump_textures); ui->toggle_custom_textures->setChecked(Settings::values.custom_textures); @@ -101,7 +104,8 @@ void ConfigureEnhancements::ApplyConfiguration() { Settings::values.layout_option = static_cast(ui->layout_combobox->currentIndex()); Settings::values.swap_screen = ui->swap_screen->isChecked(); - Settings::values.use_disk_shader_cache = ui->toggle_disk_shader_cache->isChecked(); + Settings::values.use_disk_shader_cache = + Settings::values.use_hw_shader && ui->toggle_disk_shader_cache->isChecked(); Settings::values.upright_screen = ui->upright_screen->isChecked(); Settings::values.dump_textures = ui->toggle_dump_textures->isChecked(); Settings::values.custom_textures = ui->toggle_custom_textures->isChecked(); diff --git a/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp b/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp index 1e8ca1041..d73b85db4 100644 --- a/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp +++ b/src/video_core/renderer_opengl/gl_shader_disk_cache.cpp @@ -106,7 +106,7 @@ ShaderDiskCache::ShaderDiskCache(bool separable) : separable{separable} {} std::optional> ShaderDiskCache::LoadTransferable() { const bool has_title_id = GetProgramID() != 0; - if (!Settings::values.use_disk_shader_cache || !has_title_id) + if (!Settings::values.use_hw_shader || !Settings::values.use_disk_shader_cache || !has_title_id) return {}; tried_to_load = true;