summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVíctor Manuel Jáquez Leal <vjaquez@igalia.com>2020-02-07 17:10:45 +0100
committerVíctor Manuel Jáquez Leal <vjaquez@igalia.com>2020-07-27 19:32:00 +0200
commit88f3b6b44dc7f19445f504782a2842f2153ffa6f (patch)
tree8c125deb16ae2093f113dfafa9efaf625c26a834
parent634fefab5df3caf98586cb4314ecd2deb0a59eba (diff)
downloadgstreamer-vaapi-88f3b6b44dc7f19445f504782a2842f2153ffa6f.tar.gz
vaapidecode: use allowed srcpad caps for caps query
Instead of using just the template caps use the current allowed srcpad caps, which is created considering the current decoder context. Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer-vaapi/-/merge_requests/366>
-rw-r--r--gst/vaapi/gstvaapidecode.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/gst/vaapi/gstvaapidecode.c b/gst/vaapi/gstvaapidecode.c
index 5e348ea9..017c878e 100644
--- a/gst/vaapi/gstvaapidecode.c
+++ b/gst/vaapi/gstvaapidecode.c
@@ -1433,10 +1433,9 @@ gst_vaapidecode_src_query (GstVideoDecoder * vdec, GstQuery * query)
switch (GST_QUERY_TYPE (query)) {
case GST_QUERY_CAPS:{
GstCaps *caps, *filter = NULL;
- GstPad *pad = GST_VIDEO_DECODER_SRC_PAD (vdec);
gst_query_parse_caps (query, &filter);
- caps = gst_pad_get_pad_template_caps (pad);
+ caps = gst_vaapidecode_get_allowed_srcpad_caps (GST_VAAPIDECODE (vdec));
if (filter) {
GstCaps *tmp = caps;