mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-29 19:50:40 +00:00
[500/906] gldisplay: do not call glCheckFramebufferStatus if 0 is bound
Indeed it may return GL_FRAMEBUFFER_UNDEFINED if there is no default framebuffer. It seems to be the case on MacOSX
This commit is contained in:
parent
67bc74ec3f
commit
20c429684e
1 changed files with 10 additions and 5 deletions
|
@ -2177,6 +2177,10 @@ gst_gl_display_check_framebuffer_status (void)
|
|||
GST_ERROR ("GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS");
|
||||
break;
|
||||
|
||||
case GL_FRAMEBUFFER_UNDEFINED:
|
||||
GST_ERROR ("GL_FRAMEBUFFER_UNDEFINED");
|
||||
break;
|
||||
|
||||
default:
|
||||
GST_ERROR ("General FBO error");
|
||||
}
|
||||
|
@ -3286,9 +3290,9 @@ gst_gl_display_thread_do_upload_draw (GstGLDisplay * display)
|
|||
viewport_dim[3]);
|
||||
#endif
|
||||
|
||||
glBindFramebufferEXT (GL_FRAMEBUFFER_EXT, 0);
|
||||
|
||||
gst_gl_display_check_framebuffer_status ();
|
||||
|
||||
glBindFramebufferEXT (GL_FRAMEBUFFER_EXT, 0);
|
||||
}
|
||||
|
||||
|
||||
|
@ -3578,10 +3582,10 @@ gst_gl_display_thread_do_download_draw_yuv (GstGLDisplay * display)
|
|||
viewport_dim[3]);
|
||||
#endif
|
||||
|
||||
glBindFramebufferEXT (GL_FRAMEBUFFER_EXT, 0);
|
||||
|
||||
gst_gl_display_check_framebuffer_status ();
|
||||
|
||||
glBindFramebufferEXT (GL_FRAMEBUFFER_EXT, 0);
|
||||
|
||||
glBindFramebufferEXT (GL_FRAMEBUFFER_EXT, display->download_fbo);
|
||||
#ifndef OPENGL_ES2
|
||||
glReadBuffer (GL_COLOR_ATTACHMENT0_EXT);
|
||||
|
@ -3627,6 +3631,7 @@ gst_gl_display_thread_do_download_draw_yuv (GstGLDisplay * display)
|
|||
glReadBuffer (GL_NONE);
|
||||
#endif
|
||||
|
||||
glBindFramebufferEXT (GL_FRAMEBUFFER_EXT, 0);
|
||||
gst_gl_display_check_framebuffer_status ();
|
||||
|
||||
glBindFramebufferEXT (GL_FRAMEBUFFER_EXT, 0);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue