diff --git a/pcsx2-qt/Settings/EmulationSettingsWidget.cpp b/pcsx2-qt/Settings/EmulationSettingsWidget.cpp index 150221ed5e..aca06ea4d7 100644 --- a/pcsx2-qt/Settings/EmulationSettingsWidget.cpp +++ b/pcsx2-qt/Settings/EmulationSettingsWidget.cpp @@ -67,6 +67,12 @@ EmulationSettingsWidget::EmulationSettingsWidget(SettingsDialog* dialog, QWidget dialog->registerWidgetHelp(m_ui.perGameSettings, tr("Enable Per-Game Settings"), tr("Checked"), tr("When enabled, per-game settings will be applied, and incompatible enhancements will be disabled. You should " "leave this option enabled except when testing enhancements with incompatible games.")); + dialog->registerWidgetHelp(m_ui.optimalFramePacing, tr("Optimal Frame Pacing"), tr("Unchecked"), + tr("Sets the vsync queue size to 0, making every frame be completed and presented by the GS before input is polled, and the next frame begins. " + "Using this setting can reduce input lag, at the cost of measurably higher CPU and GPU requirements.")); + dialog->registerWidgetHelp(m_ui.maxFrameLatency, tr("Maximum Frame Latency"), tr("2 Frames"), + tr("Sets the maximum number of frames that can be queued up to the GS, before the CPU thread will wait for one of them to complete before continuing. " + "Higher values can assist with smoothing out irregular frame times, but add additional input lag.")); updateOptimalFramePacing(); } @@ -163,10 +169,20 @@ void EmulationSettingsWidget::onOptimalFramePacingChanged() const QSignalBlocker sb(m_ui.maxFrameLatency); std::optional value; + bool optimal = false; if (m_ui.optimalFramePacing->checkState() != Qt::PartiallyChecked) - value = m_ui.optimalFramePacing->isChecked() ? 0 : DEFAULT_FRAME_LATENCY; + { + optimal = m_ui.optimalFramePacing->isChecked(); + value = optimal ? 0 : DEFAULT_FRAME_LATENCY; + } + else + { + value = m_dialog->getEffectiveIntValue("EmuCore/GS", "VsyncQueueSize", DEFAULT_FRAME_LATENCY); + optimal = (value == 0); + } - m_ui.maxFrameLatency->setValue(DEFAULT_FRAME_LATENCY); + m_ui.maxFrameLatency->setMinimum(optimal ? 0 : 1); + m_ui.maxFrameLatency->setValue(optimal ? 0 : DEFAULT_FRAME_LATENCY); m_ui.maxFrameLatency->setEnabled(!m_dialog->isPerGameSettings() && !m_ui.optimalFramePacing->isChecked()); m_dialog->setIntSettingValue("EmuCore/GS", "VsyncQueueSize", value); @@ -190,5 +206,6 @@ void EmulationSettingsWidget::updateOptimalFramePacing() m_ui.maxFrameLatency->setEnabled(!optimal); } - m_ui.maxFrameLatency->setValue(optimal ? DEFAULT_FRAME_LATENCY : value); + m_ui.maxFrameLatency->setMinimum(optimal ? 0 : 1); + m_ui.maxFrameLatency->setValue(optimal ? 0 : value); } diff --git a/pcsx2-qt/Settings/EmulationSettingsWidget.ui b/pcsx2-qt/Settings/EmulationSettingsWidget.ui index 844873e8a0..d0a7fb7a21 100644 --- a/pcsx2-qt/Settings/EmulationSettingsWidget.ui +++ b/pcsx2-qt/Settings/EmulationSettingsWidget.ui @@ -84,7 +84,7 @@ frames - 0 + 1 5