diff options
author | Samuel Rødal <samuel.rodal@nokia.com> | 2012-05-05 20:03:04 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-05-07 12:40:36 +0200 |
commit | f60bf8a18a09b6e81ae755918e0d98a7f3301070 (patch) | |
tree | d2aba7c2bbfba7a4e664ac91ce304ef211a00d41 /src/gui/opengl/qopenglbuffer.cpp | |
parent | 79400f83ecdb8fc4a6588609ba7fedffd58d4b5b (diff) |
Fixed QOpenGLBuffer::map and unmap implementations.
We already have the necessary enablers in QOpenGLExtensions.
Change-Id: I90d763516d8b92c09c878133552200c94a46fbf2
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
Diffstat (limited to 'src/gui/opengl/qopenglbuffer.cpp')
-rw-r--r-- | src/gui/opengl/qopenglbuffer.cpp | 25 |
1 files changed, 2 insertions, 23 deletions
diff --git a/src/gui/opengl/qopenglbuffer.cpp b/src/gui/opengl/qopenglbuffer.cpp index f47f71c121..045eec060b 100644 --- a/src/gui/opengl/qopenglbuffer.cpp +++ b/src/gui/opengl/qopenglbuffer.cpp @@ -523,18 +523,7 @@ void *QOpenGLBuffer::map(QOpenGLBuffer::Access access) #endif if (!d->guard || !d->guard->id()) return 0; -#if 0 - if (!glMapBufferARB) - return 0; - return glMapBufferARB(d->type, access); -#endif - Q_UNUSED(access); - static bool warned = false; - if (!warned) { - qWarning("QOpenGLBuffer::map(): pending implementation"); - warned = true; - } - return 0; + return d->funcs->glMapBuffer(d->type, access); } /*! @@ -559,17 +548,7 @@ bool QOpenGLBuffer::unmap() #endif if (!d->guard || !d->guard->id()) return false; -#if 0 - if (!glUnmapBufferARB) - return false; - return glUnmapBufferARB(d->type) == GL_TRUE; -#endif - static bool warned = false; - if (!warned) { - qWarning("QOpenGLBuffer::map(): pending implementation"); - warned = true; - } - return 0; + return d->funcs->glUnmapBuffer(d->type) == GL_TRUE; } QT_END_NAMESPACE |