From 08abb340625c6d281496095f2a664f27570c2b64 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Fri, 17 Oct 2014 21:44:01 +0300 Subject: [PATCH] Tweak extension behavior on Radeon --- source/extension.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/source/extension.cpp b/source/extension.cpp index fdbefb53..efa4b1a2 100644 --- a/source/extension.cpp +++ b/source/extension.cpp @@ -80,11 +80,18 @@ bool is_supported(const string &ext) string renderer = reinterpret_cast(glGetString(GL_RENDERER)); if(renderer.find("Radeon")!=string::npos) + { /* Radeon doesn't process NV_primitive_restart correctly and treats the restart index as a normal element if the indices are stored in a buffer. */ extensions.erase("GL_NV_primitive_restart"); + /* AMD's uniform buffer objects only work with the core version of + shaders. */ + if(!(get_gl_version()>=Version(2, 0))) + extensions.erase("GL_ARB_uniform_buffer_object"); + } + if(const char *disable_ptr = getenv("MSPGL_DISABLE_EXTENSIONS")) { vector disable = split(disable_ptr); -- 2.45.2