#ifndef __GLUTIL_HPP__
#define __GLUTIL_HPP__
-typedef unsigned int GLenum;
-typedef int GLint;
+#include <config.h>
-#define GL_ZERO 0x0
-#define GL_ONE 0x1
-#define GL_SRC_COLOR 0x0300
-#define GL_SRC_ALPHA 0x0302
-#define GL_ONE_MINUS_SRC_ALPHA 0x0303
-#define GL_DST_COLOR 0x0306
-
-//#include <config.h>
-
-#if 0
#ifdef HAVE_OPENGL
#include <sstream>
#include <stdexcept>
-#ifndef MACOSX
-#include <GL/gl.h>
-#include <GL/glext.h>
-#else
+#ifdef MACOSX
#include <OpenGL/gl.h>
#include <OpenGL/glext.h>
+#else
+#ifdef GL_VERSION_ES_CM_1_0
+#include <GLES/gl.h>
+#include <GLES/glext.h>
+#else
+#include <GL/gl.h>
+#include <GL/glext.h>
+#endif
#endif
static inline void check_gl_error(const char* message)
#define GL_ONE 3
#endif
-#endif
#endif