summaryrefslogtreecommitdiff
path: root/slideshow
diff options
context:
space:
mode:
authorMichael Meeks <michael.meeks@collabora.com>2015-09-08 21:25:17 +0100
committerAndras Timar <andras.timar@collabora.com>2015-09-18 10:10:34 +0200
commit29e9247b4a1bac92b4be0cfa989866044a33d70f (patch)
tree3403a33529f4d86a44e705020dcd15b493b64da3 /slideshow
parent19043bcbac41dd09ea6aee2c40133de37d04b855 (diff)
OpenGL: use CHECK_GL_ERROR() only when a context is bound.
Removes a large number of spurious GL errors left & right. Change-Id: I0b5639478812982b39d3b88be2600dad5d3f1fd0 Reviewed-on: https://gerrit.libreoffice.org/18422 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
Diffstat (limited to 'slideshow')
-rw-r--r--slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionerImpl.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionerImpl.cxx b/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionerImpl.cxx
index 9f2b60b6649d..f468f8742f42 100644
--- a/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionerImpl.cxx
+++ b/slideshow/source/engine/OGLTrans/generic/OGLTrans_TransitionerImpl.cxx
@@ -1230,11 +1230,12 @@ void SAL_CALL OGLTransitionerImpl::update( double nTime ) throw (uno::RuntimeExc
if (isDisposed() || !mbValidOpenGLContext || mpTransition->getSettings().mnRequiredGLVersion > mnGLVersion)
return;
- CHECK_GL_ERROR();
mpContext->makeCurrent();
+ CHECK_GL_ERROR();
glEnable(GL_DEPTH_TEST);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
+ CHECK_GL_ERROR();
if(mpTransition)
{
@@ -1277,8 +1278,8 @@ void SAL_CALL OGLTransitionerImpl::viewChanged( const Reference< presentation::X
void OGLTransitionerImpl::disposeTextures()
{
- CHECK_GL_ERROR();
mpContext->makeCurrent();
+ CHECK_GL_ERROR();
#if defined( GLX_EXT_texture_from_pixmap )
const GLWindow& rGLWindow(mpContext->getOpenGLWindow());