summaryrefslogtreecommitdiff
path: root/pugl/pugl.h
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2012-04-29 23:25:15 +0000
committerDavid Robillard <d@drobilla.net>2012-04-29 23:25:15 +0000
commite427c8510d56058550bf516f637d07f39676012c (patch)
tree273334bb8fded69aeff82a37605e8a12461b73d7 /pugl/pugl.h
parentd9732fbc106a6ac228912078888fbac65e78d26d (diff)
OSX implementation.
Diffstat (limited to 'pugl/pugl.h')
-rw-r--r--pugl/pugl.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/pugl/pugl.h b/pugl/pugl.h
index e5021f3..13f5efa 100644
--- a/pugl/pugl.h
+++ b/pugl/pugl.h
@@ -23,6 +23,22 @@
#include <stdint.h>
+/*
+ This API is pure portable C and contains no platform specific elements, or
+ even a GL dependency. However, unfortunately GL includes vary across
+ platforms so they are included here to allow for pure portable programs.
+*/
+#ifdef __APPLE__
+# include "OpenGL/gl.h"
+# include "OpenGL/glu.h"
+#else
+# ifdef _WIN32
+# include <windows.h> /* Broken Windows GL headers require this */
+# endif
+# include "GL/gl.h"
+# include "GL/glu.h"
+#endif
+
#ifdef __cplusplus
extern "C" {
#else