From: Sebastian Dröge Date: Thu, 17 Nov 2016 18:18:55 +0000 (+0200) Subject: textoverlay: Mark pad as needing reconfiguration again if it failed X-Git-Tag: 1.12.2~305 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d34e326425fed418024441602d13535edcae6b41;p=platform%2Fupstream%2Fgst-plugins-base.git textoverlay: Mark pad as needing reconfiguration again if it failed And return FLUSHING instead of NOT_NEGOTIATED on flushing pads. https://bugzilla.gnome.org/show_bug.cgi?id=774623 --- diff --git a/ext/pango/gstbasetextoverlay.c b/ext/pango/gstbasetextoverlay.c index 1efe703..54a6d4c 100644 --- a/ext/pango/gstbasetextoverlay.c +++ b/ext/pango/gstbasetextoverlay.c @@ -923,12 +923,16 @@ gst_base_text_overlay_negotiate (GstBaseTextOverlay * overlay, GstCaps * caps) gst_caps_unref (overlay_caps); gst_caps_unref (caps); + if (!ret) + gst_pad_mark_reconfigure (overlay->srcpad); + return ret; no_format: { if (caps) gst_caps_unref (caps); + gst_pad_mark_reconfigure (overlay->srcpad); return FALSE; } } @@ -2211,8 +2215,16 @@ gst_base_text_overlay_push_frame (GstBaseTextOverlay * overlay, if (overlay->composition == NULL) goto done; - if (gst_pad_check_reconfigure (overlay->srcpad)) - gst_base_text_overlay_negotiate (overlay, NULL); + if (gst_pad_check_reconfigure (overlay->srcpad)) { + if (!gst_base_text_overlay_negotiate (overlay, NULL)) { + gst_pad_mark_reconfigure (overlay->srcpad); + gst_buffer_unref (video_frame); + if (GST_PAD_IS_FLUSHING (overlay->srcpad)) + return GST_FLOW_FLUSHING; + else + return GST_FLOW_NOT_NEGOTIATED; + } + } video_frame = gst_buffer_make_writable (video_frame);