[Libreoffice-commits] core.git: Branch 'libreoffice-5-0' - vcl/opengl

Tomaž Vajngerl tomaz.vajngerl at collabora.co.uk
Wed Sep 16 06:36:05 PDT 2015


 vcl/opengl/framebuffer.cxx |    7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

New commits:
commit 980aa09d183da72d4fbfa6121a7aed6fd394b00a
Author: Tomaž Vajngerl <tomaz.vajngerl at collabora.co.uk>
Date:   Wed Sep 16 14:10:35 2015 +0200

    opengl: check framebuffer completeness
    
    Change-Id: Idd80b7390694038ab0913edab0e496593beb0e15
    (cherry picked from commit 7993663cc559e2a2c72804f7b4fa553f8c7441c3)
    Reviewed-on: https://gerrit.libreoffice.org/18625
    Reviewed-by: Michael Meeks <michael.meeks at collabora.com>
    Tested-by: Michael Meeks <michael.meeks at collabora.com>

diff --git a/vcl/opengl/framebuffer.cxx b/vcl/opengl/framebuffer.cxx
index b1135fc..403c379 100644
--- a/vcl/opengl/framebuffer.cxx
+++ b/vcl/opengl/framebuffer.cxx
@@ -68,8 +68,11 @@ void OpenGLFramebuffer::AttachTexture( const OpenGLTexture& rTexture )
     mnAttachedTexture = rTexture.Id();
     mnWidth = rTexture.GetWidth();
     mnHeight = rTexture.GetHeight();
-    glFramebufferTexture2D( GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D,
-                            mnAttachedTexture, 0 );
+    glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, mnAttachedTexture, 0);
+    if (glCheckFramebufferStatus(GL_FRAMEBUFFER) != GL_FRAMEBUFFER_COMPLETE)
+    {
+        SAL_WARN("vcl.opengl", "Framebuffer incomplete");
+    }
     CHECK_GL_ERROR();
 }
 


More information about the Libreoffice-commits mailing list