mirror of
https://github.com/RetroDECK/Duckstation.git
synced 2024-11-30 01:25:51 +00:00
Settings: Expose disable texture buffers/copy to self options
This commit is contained in:
parent
abbcd65563
commit
044eb589f9
|
@ -253,6 +253,10 @@ bool Host::CreateGPUDevice(RenderAPI api)
|
|||
disabled_features |= GPUDevice::FEATURE_MASK_DUAL_SOURCE_BLEND;
|
||||
if (g_settings.gpu_disable_framebuffer_fetch)
|
||||
disabled_features |= GPUDevice::FEATURE_MASK_FRAMEBUFFER_FETCH;
|
||||
if (g_settings.gpu_disable_texture_buffers)
|
||||
disabled_features |= GPUDevice::FEATURE_MASK_TEXTURE_BUFFERS;
|
||||
if (g_settings.gpu_disable_texture_copy_to_self)
|
||||
disabled_features |= GPUDevice::FEATURE_MASK_TEXTURE_COPY_TO_SELF;
|
||||
|
||||
// TODO: FSUI should always use vsync..
|
||||
const bool vsync = System::IsValid() ? System::ShouldUseVSync() : g_settings.video_sync_enabled;
|
||||
|
|
|
@ -183,6 +183,8 @@ void Settings::Load(SettingsInterface& si)
|
|||
gpu_disable_shader_cache = si.GetBoolValue("GPU", "DisableShaderCache", false);
|
||||
gpu_disable_dual_source_blend = si.GetBoolValue("GPU", "DisableDualSourceBlend", false);
|
||||
gpu_disable_framebuffer_fetch = si.GetBoolValue("GPU", "DisableFramebufferFetch", false);
|
||||
gpu_disable_texture_buffers = si.GetBoolValue("GPU", "DisableTextureBuffers", false);
|
||||
gpu_disable_texture_copy_to_self = si.GetBoolValue("GPU", "DisableTextureCopyToSelf", false);
|
||||
gpu_per_sample_shading = si.GetBoolValue("GPU", "PerSampleShading", false);
|
||||
gpu_use_thread = si.GetBoolValue("GPU", "UseThread", true);
|
||||
gpu_use_software_renderer_for_readbacks = si.GetBoolValue("GPU", "UseSoftwareRendererForReadbacks", false);
|
||||
|
@ -447,6 +449,8 @@ void Settings::Save(SettingsInterface& si) const
|
|||
si.SetBoolValue("GPU", "DisableShaderCache", gpu_disable_shader_cache);
|
||||
si.SetBoolValue("GPU", "DisableDualSourceBlend", gpu_disable_dual_source_blend);
|
||||
si.SetBoolValue("GPU", "DisableFramebufferFetch", gpu_disable_framebuffer_fetch);
|
||||
si.SetBoolValue("GPU", "DisableTextureBuffers", gpu_disable_texture_buffers);
|
||||
si.SetBoolValue("GPU", "DisableTextureCopyToSelf", gpu_disable_texture_copy_to_self);
|
||||
si.SetBoolValue("GPU", "PerSampleShading", gpu_per_sample_shading);
|
||||
si.SetBoolValue("GPU", "UseThread", gpu_use_thread);
|
||||
si.SetBoolValue("GPU", "ThreadedPresentation", gpu_threaded_presentation);
|
||||
|
|
|
@ -102,6 +102,8 @@ struct Settings
|
|||
bool gpu_disable_shader_cache = false;
|
||||
bool gpu_disable_dual_source_blend = false;
|
||||
bool gpu_disable_framebuffer_fetch = false;
|
||||
bool gpu_disable_texture_buffers = false;
|
||||
bool gpu_disable_texture_copy_to_self = false;
|
||||
bool gpu_per_sample_shading = false;
|
||||
bool gpu_true_color = true;
|
||||
bool gpu_scaled_dithering = true;
|
||||
|
|
|
@ -3516,6 +3516,8 @@ void System::CheckForSettingsChanges(const Settings& old_settings)
|
|||
g_settings.gpu_disable_shader_cache != old_settings.gpu_disable_shader_cache ||
|
||||
g_settings.gpu_disable_dual_source_blend != old_settings.gpu_disable_dual_source_blend ||
|
||||
g_settings.gpu_disable_framebuffer_fetch != old_settings.gpu_disable_framebuffer_fetch ||
|
||||
g_settings.gpu_disable_texture_buffers != old_settings.gpu_disable_texture_buffers ||
|
||||
g_settings.gpu_disable_texture_copy_to_self != old_settings.gpu_disable_texture_copy_to_self ||
|
||||
g_settings.display_exclusive_fullscreen_control != old_settings.display_exclusive_fullscreen_control))
|
||||
{
|
||||
// if debug device/threaded presentation change, we need to recreate the whole display
|
||||
|
@ -3525,6 +3527,8 @@ void System::CheckForSettingsChanges(const Settings& old_settings)
|
|||
g_settings.gpu_disable_shader_cache != old_settings.gpu_disable_shader_cache ||
|
||||
g_settings.gpu_disable_dual_source_blend != old_settings.gpu_disable_dual_source_blend ||
|
||||
g_settings.gpu_disable_framebuffer_fetch != old_settings.gpu_disable_framebuffer_fetch ||
|
||||
g_settings.gpu_disable_texture_buffers != old_settings.gpu_disable_texture_buffers ||
|
||||
g_settings.gpu_disable_texture_copy_to_self != old_settings.gpu_disable_texture_copy_to_self ||
|
||||
g_settings.display_exclusive_fullscreen_control != old_settings.display_exclusive_fullscreen_control);
|
||||
|
||||
Host::AddIconOSDMessage("RendererSwitch", ICON_FA_PAINT_ROLLER,
|
||||
|
|
|
@ -349,6 +349,10 @@ void AdvancedSettingsWidget::addTweakOptions()
|
|||
"DisableDualSourceBlend", false);
|
||||
addBooleanTweakOption(m_dialog, m_ui.tweakOptionTable, tr("Disable Framebuffer Fetch"), "GPU",
|
||||
"DisableFramebufferFetch", false);
|
||||
addBooleanTweakOption(m_dialog, m_ui.tweakOptionTable, tr("Disable Texture Buffers"), "GPU", "DisableTextureBuffers",
|
||||
false);
|
||||
addBooleanTweakOption(m_dialog, m_ui.tweakOptionTable, tr("Disable Texture Copy To Self"), "GPU",
|
||||
"DisableTextureCopyToSelf", false);
|
||||
|
||||
addBooleanTweakOption(m_dialog, m_ui.tweakOptionTable, tr("Stretch Display Vertically"), "Display",
|
||||
"StretchVertically", false);
|
||||
|
@ -400,7 +404,7 @@ void AdvancedSettingsWidget::onResetToDefaultClicked()
|
|||
setIntRangeTweakOption(m_ui.tweakOptionTable, i++,
|
||||
Settings::DEFAULT_VRAM_WRITE_DUMP_WIDTH_THRESHOLD); // Minimum dumped VRAM width
|
||||
setIntRangeTweakOption(m_ui.tweakOptionTable, i++,
|
||||
Settings::DEFAULT_VRAM_WRITE_DUMP_HEIGHT_THRESHOLD); // Minimum dumped VRAm height
|
||||
Settings::DEFAULT_VRAM_WRITE_DUMP_HEIGHT_THRESHOLD); // Minimum dumped VRAM height
|
||||
setIntRangeTweakOption(m_ui.tweakOptionTable, i++,
|
||||
static_cast<int>(Settings::DEFAULT_DMA_MAX_SLICE_TICKS)); // DMA max slice ticks
|
||||
setIntRangeTweakOption(m_ui.tweakOptionTable, i++,
|
||||
|
@ -413,6 +417,8 @@ void AdvancedSettingsWidget::onResetToDefaultClicked()
|
|||
setBooleanTweakOption(m_ui.tweakOptionTable, i++, false); // Disable Shader Cache
|
||||
setBooleanTweakOption(m_ui.tweakOptionTable, i++, false); // Disable Dual-Source Blend
|
||||
setBooleanTweakOption(m_ui.tweakOptionTable, i++, false); // Disable Framebuffer Fetch
|
||||
setBooleanTweakOption(m_ui.tweakOptionTable, i++, false); // Disable Texture Buffers
|
||||
setBooleanTweakOption(m_ui.tweakOptionTable, i++, false); // Disable Texture Copy To Self
|
||||
setBooleanTweakOption(m_ui.tweakOptionTable, i++, false); // Stretch Display Vertically
|
||||
setBooleanTweakOption(m_ui.tweakOptionTable, i++, true); // Increase Timer Resolution
|
||||
setChoiceTweakOption(m_ui.tweakOptionTable, i++,
|
||||
|
@ -463,6 +469,8 @@ void AdvancedSettingsWidget::onResetToDefaultClicked()
|
|||
sif->DeleteValue("GPU", "DisableShaderCache");
|
||||
sif->DeleteValue("GPU", "DisableDualSourceBlend");
|
||||
sif->DeleteValue("GPU", "DisableFramebufferFetch");
|
||||
sif->DeleteValue("GPU", "DisableTextureBuffers");
|
||||
sif->DeleteValue("GPU", "DisableTextureCopyToSelf");
|
||||
sif->DeleteValue("Display", "StretchVertically");
|
||||
sif->DeleteValue("Main", "IncreaseTimerResolution");
|
||||
sif->DeleteValue("CDROM", "MechaconVersion");
|
||||
|
|
Loading…
Reference in a new issue