summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Bragg <robert@linux.intel.com>2011-07-19 23:21:30 +0100
committerRobert Bragg <robert@linux.intel.com>2011-07-20 16:43:29 +0100
commit52a5fae1362692b206d7fc98b64aa0092b944583 (patch)
treebd6053b8a691629761f40c30904a0796ca8d5149
parent1144a05bfd57e925ef4280b7c0272cb2aed34689 (diff)
downloadcogl-52a5fae1362692b206d7fc98b64aa0092b944583.tar.gz
gles: don't check for glClientActiveTexture
in cogl-ext-functions.h we had one multitexture feature that checked for the ARB_multitexture extension and if found it then expected to find glActiveTexture and glClientActiveTexture. The problem is that the multitexture extension is part of the core GLES 1 and 2 APIs except that for GLES2 there is no glClientActiveTexture function. By trying to handle it as one feature that meant that Cogl would fail to check the multitexture extension which is a hard requirement for Cogl. The reason this went unnoticed is because Cogl can indirectly end up linked to an OpenGL library via cairo and so we were finding a glClientActiveTexture symbol there. This highlights that we should probably stop using g_module_open (NULL) when checking features and instead we should use the module we opened in cogl-renderer.c.
-rw-r--r--cogl/cogl-ext-functions.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/cogl/cogl-ext-functions.h b/cogl/cogl-ext-functions.h
index 45dc669e..54b6938d 100644
--- a/cogl/cogl-ext-functions.h
+++ b/cogl/cogl-ext-functions.h
@@ -598,13 +598,18 @@ COGL_EXT_END ()
/* Available in GL 1.3, the multitexture extension or GLES. These are
required */
-COGL_EXT_BEGIN (multitexture, 1, 3,
+COGL_EXT_BEGIN (multitexture_part0, 1, 3,
COGL_EXT_IN_GLES |
COGL_EXT_IN_GLES2,
"ARB\0",
"multitexture\0")
COGL_EXT_FUNCTION (void, glActiveTexture,
(GLenum texture))
+COGL_EXT_END ()
+COGL_EXT_BEGIN (multitexture_part1, 1, 3,
+ COGL_EXT_IN_GLES,
+ "ARB\0",
+ "multitexture\0")
COGL_EXT_FUNCTION (void, glClientActiveTexture,
(GLenum texture))
COGL_EXT_END ()