glimagesink: only attempt a resize when the window has already resized

fixes a black startup screen on wayland
This commit is contained in:
Matthew Waters 2014-11-27 13:01:19 +11:00
parent 2d97e03c54
commit a7ce611970

View file

@ -1260,7 +1260,8 @@ gst_glimage_sink_on_draw (GstGLImageSink * gl_sink)
/* opengl scene */
GST_TRACE ("redrawing texture:%u", gl_sink->redisplay_texture);
if (gl_sink->caps_change) {
if (gl_sink->caps_change && gl_sink->window_width > 0
&& gl_sink->window_height > 0) {
GST_GLIMAGE_SINK_UNLOCK (gl_sink);
gst_glimage_sink_on_resize (gl_sink, gl_sink->window_width,
gl_sink->window_height);