From 192d8f3601b71f896bef60838a176d14230c185a Mon Sep 17 00:00:00 2001 From: xebra Date: Sat, 7 Jan 2017 00:14:58 +0900 Subject: [PATCH] [spline/bezier]Add an option for hardware tessellation. --- Core/Config.cpp | 1 + Core/Config.h | 1 + UI/GameSettingsScreen.cpp | 3 +++ 3 files changed, 5 insertions(+) diff --git a/Core/Config.cpp b/Core/Config.cpp index 26786f3945..0a192d797b 100644 --- a/Core/Config.cpp +++ b/Core/Config.cpp @@ -493,6 +493,7 @@ static ConfigSetting graphicsSettings[] = { // Not really a graphics setting... ReportedConfigSetting("TimerHack", &g_Config.bTimerHack, &DefaultTimerHack, true, true), ReportedConfigSetting("SplineBezierQuality", &g_Config.iSplineBezierQuality, 2, true, true), + ReportedConfigSetting("HardwareTessellation", &g_Config.bHardwareTessellation, false, true, true), ReportedConfigSetting("PostShader", &g_Config.sPostShaderName, "Off", true, true), ReportedConfigSetting("MemBlockTransferGPU", &g_Config.bBlockTransferGPU, true, true, true), diff --git a/Core/Config.h b/Core/Config.h index d420c58577..d76d1b2519 100644 --- a/Core/Config.h +++ b/Core/Config.h @@ -212,6 +212,7 @@ public: bool bDisableSlowFramebufEffects; bool bFragmentTestCache; int iSplineBezierQuality; // 0 = low , 1 = Intermediate , 2 = High + bool bHardwareTessellation; std::string sPostShaderName; // Off for off. bool bGfxDebugOutput; diff --git a/UI/GameSettingsScreen.cpp b/UI/GameSettingsScreen.cpp index 3b90519980..0de0fbada4 100644 --- a/UI/GameSettingsScreen.cpp +++ b/UI/GameSettingsScreen.cpp @@ -280,6 +280,9 @@ void GameSettingsScreen::CreateViews() { }); beziersChoice->SetDisabledPtr(&g_Config.bSoftwareRendering); + CheckBox *tessellationHW = graphicsSettings->Add(new CheckBox(&g_Config.bHardwareTessellation, gr->T("Hardware Tessellation"))); + tessellationHW->SetEnabledPtr(&vtxCacheEnable_); // Same as Vertex Cache(!g_Config.bSoftwareRendering && g_Config.bHardwareTransform) + // In case we're going to add few other antialiasing option like MSAA in the future. // graphicsSettings->Add(new CheckBox(&g_Config.bFXAA, gr->T("FXAA"))); graphicsSettings->Add(new ItemHeader(gr->T("Texture Scaling")));