From: Mark Nauwelaerts Date: Fri, 22 Jul 2022 12:51:11 +0000 (+0200) Subject: videobox: avoid dropping caps fields for passthrough caps transform X-Git-Tag: 1.22.0~1207 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b5707e2371515eca10c8acf6fd8926a725c52ee9;p=platform%2Fupstream%2Fgstreamer.git videobox: avoid dropping caps fields for passthrough caps transform Fixes potential negotiation failure in case downstream element is a bit picky regarding the fields in question. Part-of: --- diff --git a/subprojects/gst-plugins-good/gst/videobox/gstvideobox.c b/subprojects/gst-plugins-good/gst/videobox/gstvideobox.c index 9c69e49..302e714 100644 --- a/subprojects/gst-plugins-good/gst/videobox/gstvideobox.c +++ b/subprojects/gst-plugins-good/gst/videobox/gstvideobox.c @@ -2949,11 +2949,13 @@ gst_video_box_transform_caps (GstBaseTransform * trans, gst_structure_set_value (structure, "format", &val); g_value_unset (&val); g_value_unset (&list); - } - - gst_structure_remove_field (structure, "colorimetry"); - gst_structure_remove_field (structure, "chroma-site"); + /* format list above makes for non-fixed caps; + * so basetransform and peers will be enlisted to decide these parts, + * otherwise leave as-is for passthrough case */ + gst_structure_remove_field (structure, "colorimetry"); + gst_structure_remove_field (structure, "chroma-site"); + } gst_caps_append_structure (to, structure); }