encodebin: Be less restrictive on muxer caps when preset name is specified
authorThibault Saunier <tsaunier@igalia.com>
Tue, 8 Sep 2020 23:45:53 +0000 (20:45 -0300)
committerGStreamer Merge Bot <gitlab-merge-bot@gstreamer-foundation.org>
Wed, 9 Sep 2020 04:26:41 +0000 (04:26 +0000)
This way the user can simply define its caps by only providing the
structure name which is what we do in the encoding profile
deserialization function for example.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-plugins-base/-/merge_requests/811>

gst/encoding/gstencodebin.c

index b8fb740..aa4837b 100644 (file)
@@ -2008,7 +2008,8 @@ _get_muxer (GstEncodeBin * ebin)
   GST_DEBUG ("Getting list of muxers for format %" GST_PTR_FORMAT, format);
 
   muxers =
-      gst_element_factory_list_filter (ebin->muxers, format, GST_PAD_SRC, TRUE);
+      gst_element_factory_list_filter (ebin->muxers, format, GST_PAD_SRC,
+      !preset_name);
 
   formatters =
       gst_element_factory_list_filter (ebin->formatters, format, GST_PAD_SRC,