Qt: Move force video timing to console settings

Since it's related to the region, it makes sense to be in here.
And it frees up precious vertical space.
pull/3396/head
Stenzek 8 months ago
parent 4afa41b927
commit 32b09193d1
No known key found for this signature in database

@ -4098,6 +4098,11 @@ void FullscreenUI::DrawConsoleSettingsPage()
DrawEnumSetting(bsi, FSUI_ICONSTR(ICON_FA_GLOBE, "Region"), FSUI_CSTR("Determines the emulated hardware type."),
"Console", "Region", Settings::DEFAULT_CONSOLE_REGION, &Settings::ParseConsoleRegionName,
&Settings::GetConsoleRegionName, &Settings::GetConsoleRegionDisplayName, ConsoleRegion::Count);
DrawEnumSetting(bsi, FSUI_ICONSTR(ICON_FA_STOPWATCH, "Frame Rate"),
FSUI_CSTR("Utilizes the chosen frame rate regardless of the game's setting."), "GPU",
"ForceVideoTiming", Settings::DEFAULT_FORCE_VIDEO_TIMING_MODE, &Settings::ParseForceVideoTimingName,
&Settings::GetForceVideoTimingName, &Settings::GetForceVideoTimingDisplayName,
ForceVideoTimingMode::Count);
DrawToggleSetting(bsi, FSUI_ICONSTR(ICON_FA_MAGIC, "Safe Mode"),
FSUI_CSTR("Temporarily disables all enhancements, useful when testing."), "Main",
"DisableAllEnhancements", false);
@ -5089,12 +5094,6 @@ void FullscreenUI::DrawGraphicsSettingsPage()
"Display", "Scaling", Settings::DEFAULT_DISPLAY_SCALING, &Settings::ParseDisplayScaling,
&Settings::GetDisplayScalingName, &Settings::GetDisplayScalingDisplayName, DisplayScalingMode::Count);
DrawEnumSetting(bsi, FSUI_ICONSTR(ICON_FA_STOPWATCH, "Force Video Timing"),
FSUI_CSTR("Utilizes the chosen video timing regardless of the game's setting."), "GPU",
"ForceVideoTiming", Settings::DEFAULT_FORCE_VIDEO_TIMING_MODE, &Settings::ParseForceVideoTimingName,
&Settings::GetForceVideoTimingName, &Settings::GetForceVideoTimingDisplayName,
ForceVideoTimingMode::Count);
if (is_hardware)
{
DrawToggleSetting(bsi, FSUI_ICONSTR(ICON_FA_PALETTE, "True Color Rendering"),
@ -9086,12 +9085,12 @@ TRANSLATE_NOOP("FullscreenUI", "File Size");
TRANSLATE_NOOP("FullscreenUI", "File Size: %u MB (%u MB on disk)");
TRANSLATE_NOOP("FullscreenUI", "File Title");
TRANSLATE_NOOP("FullscreenUI", "Force 4:3 For FMVs");
TRANSLATE_NOOP("FullscreenUI", "Force Video Timing");
TRANSLATE_NOOP("FullscreenUI", "Forces a full rescan of all games previously identified.");
TRANSLATE_NOOP("FullscreenUI", "Forces blending to be done in the shader at 16-bit precision, when not using true color. Non-trivial performance impact, and unnecessary for most games.");
TRANSLATE_NOOP("FullscreenUI", "Forces texture upload tracking to be enabled regardless of whether it is needed.");
TRANSLATE_NOOP("FullscreenUI", "Forces the use of FIFO over Mailbox presentation, i.e. double buffering instead of triple buffering. Usually results in worse frame pacing.");
TRANSLATE_NOOP("FullscreenUI", "Forcibly mutes both CD-DA and XA audio from the CD-ROM. Can be used to disable background music in some games.");
TRANSLATE_NOOP("FullscreenUI", "Frame Rate");
TRANSLATE_NOOP("FullscreenUI", "Frame Time Buffer");
TRANSLATE_NOOP("FullscreenUI", "Frequency");
TRANSLATE_NOOP("FullscreenUI", "From File...");
@ -9503,7 +9502,7 @@ TRANSLATE_NOOP("FullscreenUI", "Uses perspective-correct interpolation for color
TRANSLATE_NOOP("FullscreenUI", "Uses perspective-correct interpolation for texture coordinates, straightening out warped textures.");
TRANSLATE_NOOP("FullscreenUI", "Uses screen positions to resolve PGXP data. May improve visuals in some games.");
TRANSLATE_NOOP("FullscreenUI", "Uses separate game settings for each disc of multi-disc games. Can only be set on the first/main disc.");
TRANSLATE_NOOP("FullscreenUI", "Utilizes the chosen video timing regardless of the game's setting.");
TRANSLATE_NOOP("FullscreenUI", "Utilizes the chosen frame rate regardless of the game's setting.");
TRANSLATE_NOOP("FullscreenUI", "Value: {} | Default: {} | Minimum: {} | Maximum: {}");
TRANSLATE_NOOP("FullscreenUI", "Vertex Cache");
TRANSLATE_NOOP("FullscreenUI", "Vertical Sync (VSync)");

@ -1890,7 +1890,7 @@ static constexpr const std::array s_display_force_video_timing_names = {
};
static constexpr const std::array s_display_force_video_timing_display_names = {
TRANSLATE_DISAMBIG_NOOP("Settings", "Disabled", "ForceVideoTiming"),
TRANSLATE_DISAMBIG_NOOP("Settings", "Auto-Detect", "ForceVideoTiming"),
TRANSLATE_DISAMBIG_NOOP("Settings", "NTSC (60hz)", "ForceVideoTiming"),
TRANSLATE_DISAMBIG_NOOP("Settings", "PAL (50hz)", "ForceVideoTiming"),
};

@ -4783,7 +4783,7 @@ void System::WarnAboutUnsafeSettings()
if (g_settings.cdrom_read_speedup != 1 || g_settings.cdrom_seek_speedup != 1)
append(ICON_EMOJI_WARNING, TRANSLATE_SV("System", "CD-ROM read/seek speedup is enabled. This may crash games."));
if (g_settings.gpu_force_video_timing != ForceVideoTimingMode::Disabled)
append(ICON_FA_TV, TRANSLATE_SV("System", "Force frame timings is enabled. Games may run at incorrect speeds."));
append(ICON_FA_TV, TRANSLATE_SV("System", "Frame rate is not set to automatic. Games may run at incorrect speeds."));
if (!g_settings.IsUsingSoftwareRenderer())
{
if (g_settings.gpu_multisamples != 1)

@ -29,6 +29,16 @@ ConsoleSettingsWidget::ConsoleSettingsWidget(SettingsWindow* dialog, QWidget* pa
QString::fromUtf8(Settings::GetConsoleRegionDisplayName(static_cast<ConsoleRegion>(i))));
}
for (u32 i = 0; i < static_cast<u32>(ForceVideoTimingMode::Count); i++)
{
const ForceVideoTimingMode mode = static_cast<ForceVideoTimingMode>(i);
const QIcon region_icon =
QtUtils::GetIconForRegion((mode == ForceVideoTimingMode::Disabled) ?
ConsoleRegion::Auto :
((mode == ForceVideoTimingMode::NTSC) ? ConsoleRegion::NTSC_U : ConsoleRegion::PAL));
m_ui.forceVideoTiming->addItem(region_icon, QString::fromUtf8(Settings::GetForceVideoTimingDisplayName(mode)));
}
for (u32 i = 0; i < static_cast<u32>(CPUExecutionMode::Count); i++)
{
m_ui.cpuExecutionMode->addItem(
@ -37,11 +47,14 @@ ConsoleSettingsWidget::ConsoleSettingsWidget(SettingsWindow* dialog, QWidget* pa
SettingWidgetBinder::BindWidgetToEnumSetting(sif, m_ui.region, "Console", "Region", &Settings::ParseConsoleRegionName,
&Settings::GetConsoleRegionName, Settings::DEFAULT_CONSOLE_REGION);
SettingWidgetBinder::BindWidgetToEnumSetting(sif, m_ui.forceVideoTiming, "GPU", "ForceVideoTiming",
&Settings::ParseForceVideoTimingName, &Settings::GetForceVideoTimingName,
Settings::DEFAULT_FORCE_VIDEO_TIMING_MODE);
SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.fastBoot, "BIOS", "PatchFastBoot", false);
SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.fastForwardBoot, "BIOS", "FastForwardBoot", false);
SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.enable8MBRAM, "Console", "Enable8MBRAM", false);
SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.fastForwardMemoryCardAccess, "MemoryCards",
+"FastForwardAccess", false);
"FastForwardAccess", false);
connect(m_ui.fastBoot, &QCheckBox::checkStateChanged, this, &ConsoleSettingsWidget::onFastBootChanged);
onFastBootChanged();
@ -70,6 +83,12 @@ ConsoleSettingsWidget::ConsoleSettingsWidget(SettingsWindow* dialog, QWidget* pa
dialog->registerWidgetHelp(m_ui.region, tr("Region"), tr("Auto-Detect"),
tr("Determines the emulated hardware type."));
dialog->registerWidgetHelp(
m_ui.forceVideoTiming, tr("Force Video Timing"), tr("Disabled"),
tr("Utilizes the chosen frame timing regardless of the active region. This feature can be used to force PAL games "
"to run at 60Hz and NTSC games to run at 50Hz. For most games which have a speed tied to the framerate, this "
"will result in the game running approximately 17% faster or slower. For variable frame rate games, it may not "
"affect the speed."));
m_dialog->registerWidgetHelp(m_ui.fastBoot, tr("Fast Boot"), tr("Unchecked"),
tr("Skips the boot animation. Safe to enable."));
m_dialog->registerWidgetHelp(m_ui.fastForwardBoot, tr("Fast Forward Boot"), tr("Unchecked"),

@ -7,7 +7,7 @@
<x>0</x>
<y>0</y>
<width>648</width>
<height>459</height>
<height>468</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
@ -39,7 +39,7 @@
<item row="0" column="1">
<widget class="QComboBox" name="region"/>
</item>
<item row="1" column="0" colspan="2">
<item row="2" column="0" colspan="2">
<layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="0">
<widget class="QCheckBox" name="fastBoot">
@ -71,6 +71,16 @@
</item>
</layout>
</item>
<item row="1" column="0">
<widget class="QLabel" name="forceVideoTimingLabel">
<property name="text">
<string>Frame Rate:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="forceVideoTiming"/>
</item>
</layout>
</widget>
</item>

@ -84,9 +84,6 @@ GraphicsSettingsWidget::GraphicsSettingsWidget(SettingsWindow* dialog, QWidget*
SettingWidgetBinder::BindWidgetToEnumSetting(sif, m_ui.displayScaling, "Display", "Scaling",
&Settings::ParseDisplayScaling, &Settings::GetDisplayScalingName,
Settings::DEFAULT_DISPLAY_SCALING);
SettingWidgetBinder::BindWidgetToEnumSetting(sif, m_ui.forceVideoTiming, "GPU", "ForceVideoTiming",
&Settings::ParseForceVideoTimingName, &Settings::GetForceVideoTimingName,
Settings::DEFAULT_FORCE_VIDEO_TIMING_MODE);
SettingWidgetBinder::BindWidgetToIntSetting(sif, m_ui.gpuDownsampleScale, "GPU", "DownsampleScale", 1);
SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.trueColor, "GPU", "TrueColor", false);
SettingWidgetBinder::BindWidgetToBoolSetting(sif, m_ui.pgxpEnable, "GPU", "PGXPEnable", false);
@ -397,12 +394,6 @@ GraphicsSettingsWidget::GraphicsSettingsWidget(SettingsWindow* dialog, QWidget*
dialog->registerWidgetHelp(
m_ui.displayScaling, tr("Scaling"), tr("Bilinear (Smooth)"),
tr("Determines how the emulated console's output is upscaled or downscaled to your monitor's resolution."));
dialog->registerWidgetHelp(
m_ui.forceVideoTiming, tr("Force Video Timing"), tr("Disabled"),
tr("Utilizes the chosen frame timing regardless of the active region. This feature can be used to force PAL games "
"to run at 60Hz and NTSC games to run at 50Hz. For most games which have a speed tied to the framerate, this "
"will result in the game running approximately 17% faster or slower. For variable frame rate games, it may not "
"affect the speed."));
dialog->registerWidgetHelp(
m_ui.trueColor, tr("True Color Rendering"), tr("Checked"),
tr("Forces the precision of colours output to the console's framebuffer to use the full 8 bits of precision per "
@ -731,12 +722,6 @@ void GraphicsSettingsWidget::setupAdditionalUi()
QString::fromUtf8(Settings::GetDisplayScalingDisplayName(static_cast<DisplayScalingMode>(i))));
}
for (u32 i = 0; i < static_cast<u32>(ForceVideoTimingMode::Count); i++)
{
m_ui.forceVideoTiming->addItem(
QString::fromUtf8(Settings::GetForceVideoTimingDisplayName(static_cast<ForceVideoTimingMode>(i))));
}
// OSD Tab
const std::vector<std::string_view> fsui_theme_names = FullscreenUI::GetThemeNames();

@ -133,6 +133,19 @@
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="textureFiltering"/>
</item>
<item row="3" column="0">
<widget class="QLabel" name="spriteTextureFilteringLabel">
<property name="text">
<string>Sprite Texture Filtering:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="spriteTextureFiltering"/>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
@ -204,7 +217,7 @@
<item row="7" column="1">
<widget class="QComboBox" name="displayScaling"/>
</item>
<item row="9" column="0" colspan="2">
<item row="8" column="0" colspan="2">
<layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="1">
<widget class="QCheckBox" name="widescreenHack">
@ -250,29 +263,6 @@
</item>
</layout>
</item>
<item row="2" column="1">
<widget class="QComboBox" name="textureFiltering"/>
</item>
<item row="3" column="0">
<widget class="QLabel" name="spriteTextureFilteringLabel">
<property name="text">
<string>Sprite Texture Filtering:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QComboBox" name="spriteTextureFiltering"/>
</item>
<item row="8" column="0">
<widget class="QLabel" name="forceVideoTimingLabel">
<property name="text">
<string>Force Video Timing:</string>
</property>
</widget>
</item>
<item row="8" column="1">
<widget class="QComboBox" name="forceVideoTiming"/>
</item>
</layout>
</widget>
</item>

Loading…
Cancel
Save