diff --git a/clutter/cogl/gles/cogl-defines.h.in b/clutter/cogl/gles/cogl-defines.h.in index 2a356e873..8c0f279e9 100644 --- a/clutter/cogl/gles/cogl-defines.h.in +++ b/clutter/cogl/gles/cogl-defines.h.in @@ -31,6 +31,8 @@ G_BEGIN_DECLS +#define @COGL_GLES_VERSION@ 1 + /* ClearBufferMask */ #define CGL_DEPTH_BUFFER_BIT GL_DEPTH_BUFFER_BIT #define CGL_STENCIL_BUFFER_BIT GL_STENCIL_BUFFER_BIT @@ -163,7 +165,7 @@ G_BEGIN_DECLS #define CGL_STENCIL_PASS_DEPTH_PASS GL_STENCIL_PASS_DEPTH_PASS #define CGL_STENCIL_REF GL_STENCIL_REF #define CGL_STENCIL_WRITEMASK GL_STENCIL_WRITEMASK -#ifdef HAVE_COGL_GLES2 +#ifdef COGL_HAS_GLES2 #define CGL_MATRIX_MODE 0x0BA0 /* bad style but works for now */ #else #define CGL_MATRIX_MODE GL_MATRIX_MODE @@ -195,7 +197,7 @@ G_BEGIN_DECLS #define CGL_MAX_VIEWPORT_DIMS GL_MAX_VIEWPORT_DIMS #define CGL_MAX_ELEMENTS_VERTICES GL_MAX_ELEMENTS_VERTICES #define CGL_MAX_ELEMENTS_INDICES GL_MAX_ELEMENTS_INDICES -#ifdef HAVE_COGL_GLES2 +#ifdef COGL_HAS_GLES2 #define CGL_MAX_COMBINED_TEXTURE_IMAGE_UNITS GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS #else #define CGL_MAX_COMBINED_TEXTURE_IMAGE_UNITS GL_MAX_TEXTURE_UNITS diff --git a/configure.ac b/configure.ac index 99b880fc4..b314e3480 100644 --- a/configure.ac +++ b/configure.ac @@ -135,6 +135,7 @@ AS_IF([test "x$clutterbackend" = "xeglnative" || CLUTTER_COGL="gles" AC_DEFINE([HAVE_COGL_GLES], 1, [Have GL/ES for rendering]) + AC_SUBST(COGL_GLES_VERSION, [COGL_HAS_GLES1]) AC_CHECK_HEADERS([GLES/egl.h], [], @@ -179,6 +180,7 @@ AS_IF([test "x$clutterbackend" = "xeglnative" || use_gles2_wrapper=yes CLUTTER_COGL="gles" AC_DEFINE([HAVE_COGL_GLES2], 1, [Have GL/ES for rendering]) + AC_SUBST(COGL_GLES_VERSION, [COGL_HAS_GLES2]) AC_CHECK_HEADERS([EGL/egl.h], [], @@ -192,6 +194,7 @@ AS_IF([test "x$clutterbackend" = "xeglnative" || clutter_gl_header="GLES/gl.h" CLUTTER_COGL="gles" AC_DEFINE([HAVE_COGL_GLES], 1, [Have GL/ES for rendering]) + AC_SUBST(COGL_GLES_VERSION, [COGL_HAS_GLES1]) AC_CHECK_HEADERS([GLES/egl.h], [],