summaryrefslogtreecommitdiffstats
path: root/src/opengl/qgl.cpp
diff options
context:
space:
mode:
authorOlivier Goffart <olivier.goffart@nokia.com>2010-12-06 15:43:57 (GMT)
committerOlivier Goffart <olivier.goffart@nokia.com>2010-12-06 15:43:57 (GMT)
commit9888fa259875d82bf08a28cac134fe6f71f371f0 (patch)
treea58a6ab673888d5c352d2cfe98b22fb1c11c40e9 /src/opengl/qgl.cpp
parenta70ccc4aaad74dbf28569c78479d4668781bb0fe (diff)
parent9327490ad51b737211c26cae53a095a8485e2dad (diff)
downloadQt-9888fa259875d82bf08a28cac134fe6f71f371f0.zip
Qt-9888fa259875d82bf08a28cac134fe6f71f371f0.tar.gz
Qt-9888fa259875d82bf08a28cac134fe6f71f371f0.tar.bz2
Merge remote branch 'origin/4.7' into qt-master-from-4.7
Conflicts: configure qmake/generators/win32/msbuild_objectmodel.cpp src/gui/image/qpnghandler.cpp src/network/access/qnetworkaccessdatabackend.cpp src/opengl/qgl_x11egl.cpp tests/auto/qnetworkreply/tst_qnetworkreply.cpp
Diffstat (limited to 'src/opengl/qgl.cpp')
-rw-r--r--src/opengl/qgl.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/opengl/qgl.cpp b/src/opengl/qgl.cpp
index dc7a333..8b31849 100644
--- a/src/opengl/qgl.cpp
+++ b/src/opengl/qgl.cpp
@@ -2125,7 +2125,9 @@ void QGLContextPrivate::cleanup()
void QGLContextPrivate::setVertexAttribArrayEnabled(int arrayIndex, bool enabled)
{
Q_ASSERT(arrayIndex < QT_GL_VERTEX_ARRAY_TRACKED_COUNT);
+#ifdef glEnableVertexAttribArray
Q_ASSERT(glEnableVertexAttribArray);
+#endif
if (vertexAttributeArraysEnabledState[arrayIndex] && !enabled)
glDisableVertexAttribArray(arrayIndex);
@@ -2138,7 +2140,9 @@ void QGLContextPrivate::setVertexAttribArrayEnabled(int arrayIndex, bool enabled
void QGLContextPrivate::syncGlState()
{
+#ifdef glEnableVertexAttribArray
Q_ASSERT(glEnableVertexAttribArray);
+#endif
for (int i = 0; i < QT_GL_VERTEX_ARRAY_TRACKED_COUNT; ++i) {
if (vertexAttributeArraysEnabledState[i])
glEnableVertexAttribArray(i);