From d90b6ec45979fdd2b3fdd114d523d78d8395a2f1 Mon Sep 17 00:00:00 2001 From: Nicolas Dufresne Date: Thu, 21 Dec 2017 22:56:51 -0500 Subject: [PATCH] v4l2videoenc: Call stop on object before renegotiation Otherwise renegotiation fails as we are still streaming. https://bugzilla.gnome.org/show_bug.cgi?id=791338 --- sys/v4l2/gstv4l2videoenc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/v4l2/gstv4l2videoenc.c b/sys/v4l2/gstv4l2videoenc.c index 1783b860a6..c9a8040f44 100644 --- a/sys/v4l2/gstv4l2videoenc.c +++ b/sys/v4l2/gstv4l2videoenc.c @@ -321,6 +321,9 @@ gst_v4l2_video_enc_set_format (GstVideoEncoder * encoder, if (gst_v4l2_video_enc_finish (encoder) != GST_FLOW_OK) return FALSE; + gst_v4l2_object_stop (self->v4l2output); + gst_v4l2_object_stop (self->v4l2capture); + gst_video_codec_state_unref (self->input_state); self->input_state = NULL; }