mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 20:21:24 +00:00
vaapisink: fix get_caps() implementation for GStreamer 1.0.
Fix GstBaseSink::get_caps() implementation for GStreamer 1.0.X builds by honouring the filter caps argument. More precisely, this fixes the following pipeline: gst-launch-1.0 videotestsrc ! vaapisink https://bugzilla.gnome.org/show_bug.cgi?id=705192 Signed-off-by: Guangxin.Xu <Guangxin.Xu@intel.com> Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
This commit is contained in:
parent
d16db58968
commit
92a124f306
1 changed files with 11 additions and 1 deletions
|
@ -720,7 +720,17 @@ gst_vaapisink_get_caps_impl(GstBaseSink *base_sink)
|
|||
static inline GstCaps *
|
||||
gst_vaapisink_get_caps(GstBaseSink *base_sink, GstCaps *filter)
|
||||
{
|
||||
return gst_vaapisink_get_caps_impl(base_sink);
|
||||
GstCaps *caps, *out_caps;
|
||||
|
||||
caps = gst_vaapisink_get_caps_impl(base_sink);
|
||||
if (caps && filter) {
|
||||
out_caps = gst_caps_intersect_full(caps, filter,
|
||||
GST_CAPS_INTERSECT_FIRST);
|
||||
gst_caps_unref(caps);
|
||||
}
|
||||
else
|
||||
out_caps = caps;
|
||||
return out_caps;
|
||||
}
|
||||
#else
|
||||
#define gst_vaapisink_get_caps gst_vaapisink_get_caps_impl
|
||||
|
|
Loading…
Reference in a new issue