gl/clutter: safer check for cogl version

Use COGL_VERSION_ENCODE to check for the minimum required and maximum allowed
cogl version. In certain situations just using the COGL_VERSION_* macro name can
give you the following error:

error "COGL_VERSION_MAX_ALLOWED must be >= COGL_VERSION_MIN_REQUIRED"
This commit is contained in:
Luis de Bethencourt 2014-05-03 21:38:42 -04:00 committed by Tim-Philipp Müller
parent f29a98cc5f
commit 64a144f114

View file

@ -25,8 +25,8 @@
#define CLUTTER_VERSION_MIN_REQUIRED CLUTTER_VERSION_1_8
#define CLUTTER_VERSION_MAX_ALLOWED CLUTTER_VERSION_1_10
#define COGL_VERSION_MIN_REQUIRED COGL_VERSION_1_16
#define COGL_VERSION_MAX_ALLOWED COGL_VERSION_1_18
#define COGL_VERSION_MIN_REQUIRED COGL_VERSION_ENCODE (1, 16, 0)
#define COGL_VERSION_MAX_ALLOWED COGL_VERSION_ENCODE (1, 18, 0)
#include <clutter/clutter.h>
#ifndef WIN32
#include <clutter/x11/clutter-x11.h>