diff options
author | Allan Sandfeld Jensen <allan.jensen@digia.com> | 2014-09-30 14:30:00 +0200 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@digia.com> | 2014-09-30 19:59:23 +0200 |
commit | 56f3eb299c5e82d5b1576eed0c879475e18d7e0a (patch) | |
tree | 0507b95214e8c7423797bf894de6211c2e4a7cd3 /src/gui/opengl/qopenglvertexarrayobject_p.h | |
parent | be1635e2d6a4e42f3f828e7831e5dbf867ba161d (diff) |
Extend QOpenGLVertexArrayObjectHelper to support glIsVertexArrays
This is needed for dynamicgl support in QtWebKit.
Change-Id: I4d1769394ccdeaf449cac4f002c03ca8013f62f6
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Diffstat (limited to 'src/gui/opengl/qopenglvertexarrayobject_p.h')
-rw-r--r-- | src/gui/opengl/qopenglvertexarrayobject_p.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/gui/opengl/qopenglvertexarrayobject_p.h b/src/gui/opengl/qopenglvertexarrayobject_p.h index 3c06254baa..366d7ae2f6 100644 --- a/src/gui/opengl/qopenglvertexarrayobject_p.h +++ b/src/gui/opengl/qopenglvertexarrayobject_p.h @@ -67,13 +67,14 @@ public: : GenVertexArrays(Q_NULLPTR) , DeleteVertexArrays(Q_NULLPTR) , BindVertexArray(Q_NULLPTR) + , IsVertexArray(Q_NULLPTR) { qtInitializeVertexArrayObjectHelper(this, context); } inline bool isValid() const { - return GenVertexArrays && DeleteVertexArrays && BindVertexArray; + return GenVertexArrays && DeleteVertexArrays && BindVertexArray && IsVertexArray; } inline void glGenVertexArrays(GLsizei n, GLuint *arrays) const @@ -91,6 +92,11 @@ public: BindVertexArray(array); } + inline GLboolean glIsVertexArray(GLuint array) const + { + return IsVertexArray(array); + } + private: friend void Q_GUI_EXPORT qtInitializeVertexArrayObjectHelper(QOpenGLVertexArrayObjectHelper *helper, QOpenGLContext *context); @@ -98,10 +104,12 @@ private: typedef void (QOPENGLF_APIENTRYP qt_GenVertexArrays_t)(GLsizei n, GLuint *arrays); typedef void (QOPENGLF_APIENTRYP qt_DeleteVertexArrays_t)(GLsizei n, const GLuint *arrays); typedef void (QOPENGLF_APIENTRYP qt_BindVertexArray_t)(GLuint array); + typedef GLboolean (QOPENGLF_APIENTRYP qt_IsVertexArray_t)(GLuint array); qt_GenVertexArrays_t GenVertexArrays; qt_DeleteVertexArrays_t DeleteVertexArrays; qt_BindVertexArray_t BindVertexArray; + qt_IsVertexArray_t IsVertexArray; }; QT_END_NAMESPACE |