summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorZolnai Tamás <tamas.zolnai@collabora.com>2014-07-21 14:21:25 +0200
committerCaolán McNamara <caolanm@redhat.com>2014-07-21 19:21:48 +0000
commit3c2ce3618f586d932b516c15167a79f2b882fbf5 (patch)
tree7c306cf0bf8fa2f2fa529b143e3e300ec1c7fdc0 /include
parentf6445efb0e5c3de099f0425825fe1e6e8271dfb9 (diff)
fdo#81055: Crash due to inadequate checks for GL version / capabilities
Base line is OpenGL 2.1 + extensions. GL_ARB_framebuffer_object (part of OpenGL 3.0) for glGenFramebuffers, glGenRenderbuffers... GL_ARB_vertex_array_object (part of OpenGL 3.0) for glGenVertexArrays, glBindVertexArray... GL_ARB_sampler_objects (part of OpenGL 3.3) for glGenSamplers, glBindSampler... (cherry picked from commit 378b1d24a958114eb4484cb10f609f6e482772ec) (and cherry picked some part of commit 23c876deeb357b6306712ff0586a819176151c15) Change-Id: I3a3caeab7ef593188ee742c53e6715648bf14f50 Reviewed-on: https://gerrit.libreoffice.org/10440 Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'include')
-rw-r--r--include/vcl/opengl/OpenGLHelper.hxx3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/vcl/opengl/OpenGLHelper.hxx b/include/vcl/opengl/OpenGLHelper.hxx
index 475bd720c082..58c3d15224e8 100644
--- a/include/vcl/opengl/OpenGLHelper.hxx
+++ b/include/vcl/opengl/OpenGLHelper.hxx
@@ -36,6 +36,9 @@ public:
*/
static void createFramebuffer(long nWidth, long nHeight,
GLuint& nFramebufferId, GLuint& nRenderbufferTextId, GLuint& nRenderbufferColorId);
+
+ // Get OpenGL version (needs a context)
+ static float getGLVersion();
};
VCLOPENGL_DLLPUBLIC std::ostream& operator<<(std::ostream& rStrm, const glm::mat4& rMatrix);