diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/system-gl.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/tests/system-gl.h b/tests/system-gl.h new file mode 100644 index 0000000..ddc2cf2 --- /dev/null +++ b/tests/system-gl.h @@ -0,0 +1,14 @@ +#ifndef SYSTEMGL_H_ +#define SYSTEMGL_H_ + +#ifdef __APPLE__ +#include <OpenGL/OpenGL.h> +#include <OpenGL/glu.h> // for gluCheckExtension +#else +#include <GL/glew.h> +#include <GL/gl.h> +#endif + +#define REPORTGLERROR(task) { GLenum tGLErr = glGetError(); if (tGLErr != GL_NO_ERROR) { std::cout << "OpenGL error " << tGLErr << " while " << task << "\n"; } } + +#endif |