summaryrefslogtreecommitdiffstats
path: root/src/gui/opengl/qopengl.h
diff options
context:
space:
mode:
authorSean Harmer <sean.harmer@kdab.com>2013-02-01 13:20:19 +0000
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-02-21 20:39:23 +0100
commit25c90050974714b5582df5ef9609be4efe4e771a (patch)
tree47f9b85630f3cc3cd2f6fb4a4e3b402250530c28 /src/gui/opengl/qopengl.h
parent22077e1609c8a5af39d48ddfb65066581ef15c0d (diff)
OpenGL: Refactor some defines and typedefs to a common location
These will be needed by the upcoming OpenGL enablers so move them out of qopenglfunctions.h to somewhere that any opengl related file can access them. Change-Id: I0c788559397d446ec7210e2ad940da862179710d Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
Diffstat (limited to 'src/gui/opengl/qopengl.h')
-rw-r--r--src/gui/opengl/qopengl.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/gui/opengl/qopengl.h b/src/gui/opengl/qopengl.h
index a4a626a0c4..e1d36662d1 100644
--- a/src/gui/opengl/qopengl.h
+++ b/src/gui/opengl/qopengl.h
@@ -108,6 +108,23 @@ typedef GLfloat GLdouble;
QT_BEGIN_NAMESPACE
+// Types that aren't defined in all system's gl.h files.
+typedef ptrdiff_t qopengl_GLintptr;
+typedef ptrdiff_t qopengl_GLsizeiptr;
+
+
+#if defined(APIENTRY) && !defined(QOPENGLF_APIENTRY)
+# define QOPENGLF_APIENTRY APIENTRY
+#endif
+
+# ifndef QOPENGLF_APIENTRYP
+# ifdef QOPENGLF_APIENTRY
+# define QOPENGLF_APIENTRYP QOPENGLF_APIENTRY *
+# else
+# define QOPENGLF_APIENTRY
+# define QOPENGLF_APIENTRYP *
+# endif
+# endif
QT_END_NAMESPACE