Add a GR for GI in central_settings

This commit is contained in:
Vincent Lejeune 2015-02-18 23:42:42 +01:00
parent 5f9e4086af
commit 1a861c742c
4 changed files with 10 additions and 1 deletions

View File

@ -27,6 +27,7 @@ void CentralVideoSettings::init()
hasTextureCompression = false;
hasUBO = false;
hasGS = false;
m_GI_has_artifact = false;
m_need_rh_workaround = false;
m_need_srgb_workaround = false;
@ -140,6 +141,11 @@ void CentralVideoSettings::init()
UserConfigParams::m_high_definition_textures = 0x00;
}
if (!GraphicsRestrictions::isDisabled(GraphicsRestrictions::GR_GI))
{
m_GI_has_artifact = true;
}
// Specific disablement
if (strstr((const char *)glGetString(GL_VENDOR), "NVIDIA") != NULL)
{
@ -263,7 +269,7 @@ bool CentralVideoSettings::supportsShadows() const
bool CentralVideoSettings::supportsGlobalIllumination() const
{
return isARBGeometryShader4Usable() && isARBUniformBufferObjectUsable();
return isARBGeometryShader4Usable() && isARBUniformBufferObjectUsable() && !m_GI_has_artifact;
}
bool CentralVideoSettings::supportsIndirectInstancingRendering() const

View File

@ -26,6 +26,7 @@ private:
bool m_need_rh_workaround;
bool m_need_srgb_workaround;
bool m_GI_has_artifact;
public:
void init();
bool isGLSL() const;

View File

@ -59,6 +59,7 @@ namespace GraphicsRestrictions
"HighDefinitionTextures",
"AdvancedPipeline",
"FramebufferSRGBWorking",
"GI",
};
} // namespace Private
using namespace Private;

View File

@ -53,6 +53,7 @@ namespace GraphicsRestrictions
GR_HIGHDEFINITION_TEXTURES,
GR_ADVANCED_PIPELINE,
GR_FRAMEBUFFER_SRGB_WORKING,
GR_GI,
GR_COUNT /** MUST be last entry. */
} ;