From ea80952998256e0510361df2d7f38145db72295e Mon Sep 17 00:00:00 2001 From: =?utf8?q?Sebastian=20Dr=C3=B6ge?= Date: Fri, 15 Apr 2022 16:53:25 +0300 Subject: [PATCH] x264enc: Don't try to fixate ANY allowed caps Instead fall back to the template caps. Part-of: --- subprojects/gst-plugins-ugly/ext/x264/gstx264enc.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/subprojects/gst-plugins-ugly/ext/x264/gstx264enc.c b/subprojects/gst-plugins-ugly/ext/x264/gstx264enc.c index 70f73c5..43765b3 100644 --- a/subprojects/gst-plugins-ugly/ext/x264/gstx264enc.c +++ b/subprojects/gst-plugins-ugly/ext/x264/gstx264enc.c @@ -2272,6 +2272,11 @@ gst_x264_enc_set_format (GstVideoEncoder * video_enc, return FALSE; } + if (gst_caps_is_any (allowed_caps)) { + gst_caps_unref (allowed_caps); + allowed_caps = gst_caps_ref (template_caps); + } + allowed_caps = gst_caps_make_writable (allowed_caps); allowed_caps = gst_caps_fixate (allowed_caps); s = gst_caps_get_structure (allowed_caps, 0); -- 2.7.4