qmlsink: Ensure that at least one windowing system is available

Otherwise, we'll just crash at runtime because the gl context is NULL

https://bugzilla.gnome.org/show_bug.cgi?id=754108
This commit is contained in:
Nirbheek Chauhan 2015-08-07 17:27:48 +05:30 committed by Tim-Philipp Müller
parent 9846984c63
commit e99c591dc9

View file

@ -37,7 +37,7 @@
#include <gst/gl/x11/gstglcontext_glx.h> #include <gst/gl/x11/gstglcontext_glx.h>
#endif #endif
#if GST_GL_HAVE_WINDOW_WAYLAND #if GST_GL_HAVE_WINDOW_WAYLAND && defined (HAVE_QT_WAYLAND)
#include <gst/gl/wayland/gstgldisplay_wayland.h> #include <gst/gl/wayland/gstgldisplay_wayland.h>
#endif #endif
@ -273,7 +273,7 @@ QtGLVideoItem::onSceneGraphInitialized ()
platform, gl_api); platform, gl_api);
} }
#endif #endif
#if GST_GL_HAVE_WINDOW_WAYLAND #if GST_GL_HAVE_WINDOW_WAYLAND && defined (HAVE_QT_WAYLAND)
if (GST_IS_GL_DISPLAY_WAYLAND (this->priv->display)) { if (GST_IS_GL_DISPLAY_WAYLAND (this->priv->display)) {
platform = GST_GL_PLATFORM_EGL; platform = GST_GL_PLATFORM_EGL;
gl_api = gst_gl_context_get_current_gl_api (platform, NULL, NULL); gl_api = gst_gl_context_get_current_gl_api (platform, NULL, NULL);