From 33ef4ec817f5094381f8fb4fa2682e08e4583409 Mon Sep 17 00:00:00 2001 From: He Junyan Date: Sat, 11 Jul 2020 23:39:40 +0800 Subject: [PATCH] plugin: encode: vp9: Add the profile into output caps. Part-of: --- gst/vaapi/gstvaapiencode_vp9.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/gst/vaapi/gstvaapiencode_vp9.c b/gst/vaapi/gstvaapiencode_vp9.c index 4538462003..c1cfb778bc 100644 --- a/gst/vaapi/gstvaapiencode_vp9.c +++ b/gst/vaapi/gstvaapiencode_vp9.c @@ -80,8 +80,14 @@ static GstCaps * gst_vaapiencode_vp9_get_caps (GstVaapiEncode * base_encode) { GstCaps *caps; + GstVaapiProfile profile; + const gchar *profile_str; caps = gst_caps_from_string (GST_CODEC_CAPS); + profile = gst_vaapi_encoder_get_profile (base_encode->encoder); + profile_str = gst_vaapi_utils_vp9_get_profile_string (profile); + if (profile_str) + gst_caps_set_simple (caps, "profile", G_TYPE_STRING, profile_str, NULL); return caps; }