summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qopenglcontext.h
diff options
context:
space:
mode:
authorSamuel Rødal <samuel.rodal@nokia.com>2012-01-26 11:44:05 +0100
committerQt by Nokia <qt-info@nokia.com>2012-01-27 10:58:32 +0100
commit2d39471897f0a3a769406ec9c2b39558ebd45af3 (patch)
tree8c417f4ba814e9dbe70e56bdbf8a13cc46b3827f /src/gui/kernel/qopenglcontext.h
parent365b5f7a9271e5fc503b10e6c17371d76643fc94 (diff)
Introduced QOpenGLContext::defaultFramebufferObject().
Also add some debugging helpers to make sure applications are correctly written even on less restrictive platforms. Change-Id: Ie92e497c32e07b2b83662f7ab5540d8f37777fd0 Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
Diffstat (limited to 'src/gui/kernel/qopenglcontext.h')
-rw-r--r--src/gui/kernel/qopenglcontext.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/gui/kernel/qopenglcontext.h b/src/gui/kernel/qopenglcontext.h
index 2d86a6db31..449c75f22a 100644
--- a/src/gui/kernel/qopenglcontext.h
+++ b/src/gui/kernel/qopenglcontext.h
@@ -50,11 +50,17 @@
#include <QtGui/QSurfaceFormat>
+#ifdef __GLEW_H__
+#warning qopenglfunctions.h is not compatible with GLEW, GLEW defines will be undefined
+#warning To use GLEW with Qt, do not include <qopengl.h> or <QOpenGLFunctions> after glew.h
+#endif
+
+#include <QtGui/qopengl.h>
+
QT_BEGIN_HEADER
QT_BEGIN_NAMESPACE
-
class QOpenGLContextPrivate;
class QOpenGLContextGroupPrivate;
class QOpenGLFunctions;
@@ -103,6 +109,8 @@ public:
QOpenGLContextGroup *shareGroup() const;
QScreen *screen() const;
+ GLuint defaultFramebufferObject() const;
+
bool makeCurrent(QSurface *surface);
void doneCurrent();