Core / DolphinQt / VideoCommon: add setting for enabling graphic mods

This commit is contained in:
iwubcode 2022-04-07 00:00:38 -05:00
parent f416b71925
commit 0f88155729
6 changed files with 15 additions and 1 deletions

View File

@ -101,6 +101,8 @@ const Info<int> GFX_SW_DRAW_END{{System::GFX, "Settings", "SWDrawEnd"}, 100000};
const Info<bool> GFX_PREFER_GLES{{System::GFX, "Settings", "PreferGLES"}, false};
const Info<bool> GFX_MODS_ENABLE{{System::GFX, "Settings", "EnableMods"}, false};
// Graphics.Enhancements
const Info<bool> GFX_ENHANCE_FORCE_FILTERING{{System::GFX, "Enhancements", "ForceFiltering"},

View File

@ -82,6 +82,8 @@ extern const Info<int> GFX_SW_DRAW_END;
extern const Info<bool> GFX_PREFER_GLES;
extern const Info<bool> GFX_MODS_ENABLE;
// Graphics.Enhancements
extern const Info<bool> GFX_ENHANCE_FORCE_FILTERING;

View File

@ -72,13 +72,15 @@ void AdvancedWidget::CreateWidgets()
m_dump_xfb_target = new GraphicsBool(tr("Dump XFB Target"), Config::GFX_DUMP_XFB_TARGET);
m_disable_vram_copies =
new GraphicsBool(tr("Disable EFB VRAM Copies"), Config::GFX_HACK_DISABLE_COPY_TO_VRAM);
m_enable_graphics_mods = new GraphicsBool(tr("Enable Graphics Mods"), Config::GFX_MODS_ENABLE);
utility_layout->addWidget(m_load_custom_textures, 0, 0);
utility_layout->addWidget(m_prefetch_custom_textures, 0, 1);
utility_layout->addWidget(m_disable_vram_copies, 1, 0);
utility_layout->addWidget(m_enable_graphics_mods, 1, 1);
utility_layout->addWidget(m_dump_efb_target, 1, 1);
utility_layout->addWidget(m_dump_efb_target, 2, 0);
utility_layout->addWidget(m_dump_xfb_target, 2, 1);
// Texture dumping
@ -245,6 +247,9 @@ void AdvancedWidget::AddDescriptions()
QT_TR_NOOP("Disables the VRAM copy of the EFB, forcing a round-trip to RAM. Inhibits all "
"upscaling.<br><br><dolphin_emphasis>If unsure, leave this "
"unchecked.</dolphin_emphasis>");
static const char TR_LOAD_GRAPHICS_MODS_DESCRIPTION[] =
QT_TR_NOOP("Loads graphics mods from User/Load/GraphicsMods/.<br><br><dolphin_emphasis>If "
"unsure, leave this unchecked.</dolphin_emphasis>");
static const char TR_INTERNAL_RESOLUTION_FRAME_DUMPING_DESCRIPTION[] = QT_TR_NOOP(
"Creates frame dumps and screenshots at the internal resolution of the renderer, rather than "
"the size of the window it is displayed within.<br><br>If the aspect ratio is widescreen, "
@ -316,6 +321,7 @@ void AdvancedWidget::AddDescriptions()
m_dump_efb_target->SetDescription(tr(TR_DUMP_EFB_DESCRIPTION));
m_dump_xfb_target->SetDescription(tr(TR_DUMP_XFB_DESCRIPTION));
m_disable_vram_copies->SetDescription(tr(TR_DISABLE_VRAM_COPIES_DESCRIPTION));
m_enable_graphics_mods->SetDescription(tr(TR_LOAD_GRAPHICS_MODS_DESCRIPTION));
m_use_fullres_framedumps->SetDescription(tr(TR_INTERNAL_RESOLUTION_FRAME_DUMPING_DESCRIPTION));
#ifdef HAVE_FFMPEG
m_dump_use_ffv1->SetDescription(tr(TR_USE_FFV1_DESCRIPTION));

View File

@ -42,6 +42,7 @@ private:
GraphicsBool* m_dump_xfb_target;
GraphicsBool* m_disable_vram_copies;
GraphicsBool* m_load_custom_textures;
GraphicsBool* m_enable_graphics_mods;
// Texture dumping
GraphicsBool* m_dump_textures;

View File

@ -145,6 +145,8 @@ void VideoConfig::Refresh()
bFastTextureSampling = Config::Get(Config::GFX_HACK_FAST_TEXTURE_SAMPLING);
bPerfQueriesEnable = Config::Get(Config::GFX_PERF_QUERIES_ENABLE);
bGraphicMods = Config::Get(Config::GFX_MODS_ENABLE);
}
void VideoConfig::VerifyValidity()

View File

@ -111,6 +111,7 @@ struct VideoConfig final
bool bBorderlessFullscreen = false;
bool bEnableGPUTextureDecoding = false;
int iBitrateKbps = 0;
bool bGraphicMods = false;
// Hacks
bool bEFBAccessEnable = false;