System: Add "Disable Mailbox Presentation" option

Partial backport of https://github.com/PCSX2/pcsx2/pull/11296
This commit is contained in:
Stenzek
2024-05-26 22:30:34 +10:00
parent 83df785558
commit 55d96f86f0
7 changed files with 53 additions and 22 deletions

View File

@ -124,7 +124,10 @@ GraphicsSettingsWidget::GraphicsSettingsWidget(SettingsWindow* dialog, QWidget*
&Settings::ParseDisplayAlignment, &Settings::GetDisplayAlignmentName,
Settings::DEFAULT_DISPLAY_ALIGNMENT);
SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.gpuThread, "GPU", "UseThread", true);
SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.threadedPresentation, "GPU", "ThreadedPresentation", true);
SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.threadedPresentation, "GPU", "ThreadedPresentation",
Settings::DEFAULT_THREADED_PRESENTATION);
SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.disableMailboxPresentation, "Display",
"DisableMailboxPresentation", false);
SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.stretchDisplayVertically, "Display", "StretchVertically",
false);
#ifdef _WIN32
@ -334,6 +337,10 @@ GraphicsSettingsWidget::GraphicsSettingsWidget(SettingsWindow* dialog, QWidget*
dialog->registerWidgetHelp(m_ui.threadedPresentation, tr("Threaded Presentation"), tr("Checked"),
tr("Presents frames on a background thread when fast forwarding or vsync is disabled. "
"This can measurably improve performance in the Vulkan renderer."));
dialog->registerWidgetHelp(
m_ui.disableMailboxPresentation, tr("Disable Mailbox Presentation"), tr("Unchecked"),
tr("Forces the use of FIFO over Mailbox presentation, i.e. double buffering instead of triple buffering. "
"Usually results in worse frame pacing."));
dialog->registerWidgetHelp(
m_ui.stretchDisplayVertically, tr("Stretch Vertically"), tr("Unchecked"),
tr("Prefers stretching the display vertically instead of horizontally, when applying the display aspect ratio."));

View File

@ -417,20 +417,6 @@
</item>
<item row="2" column="0" colspan="2">
<layout class="QGridLayout" name="advancedDisplayOptionsLayout">
<item row="1" column="1">
<widget class="QCheckBox" name="blitSwapChain">
<property name="text">
<string>Use Blit Swap Chain</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QCheckBox" name="stretchDisplayVertically">
<property name="text">
<string>Stretch Vertically</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QCheckBox" name="threadedPresentation">
<property name="text">
@ -439,9 +425,23 @@
</widget>
</item>
<item row="0" column="0">
<widget class="QCheckBox" name="gpuThread">
<widget class="QCheckBox" name="blitSwapChain">
<property name="text">
<string>Threaded Rendering</string>
<string>Use Blit Swap Chain</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QCheckBox" name="stretchDisplayVertically">
<property name="text">
<string>Stretch Vertically</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QCheckBox" name="disableMailboxPresentation">
<property name="text">
<string>Disable Mailbox Presentation</string>
</property>
</widget>
</item>
@ -482,13 +482,20 @@
</property>
</widget>
</item>
<item row="1" column="0">
<item row="1" column="1">
<widget class="QCheckBox" name="useSoftwareRendererForReadbacks">
<property name="text">
<string>Software Renderer Readbacks</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QCheckBox" name="gpuThread">
<property name="text">
<string>Threaded Rendering</string>
</property>
</widget>
</item>
</layout>
</item>
<item row="0" column="0">