From 0df7af07ce0df6082851aeaa866666abb0945d67 Mon Sep 17 00:00:00 2001 From: Alessandro Decina Date: Thu, 25 Jul 2013 08:22:45 +0200 Subject: [PATCH] osxaudiosink: intersect the probed caps with the filter passed to get_caps() --- sys/osxaudio/gstosxaudiosink.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sys/osxaudio/gstosxaudiosink.c b/sys/osxaudio/gstosxaudiosink.c index 053a871..8f01a3b 100644 --- a/sys/osxaudio/gstosxaudiosink.c +++ b/sys/osxaudio/gstosxaudiosink.c @@ -315,6 +315,9 @@ gst_osx_audio_sink_getcaps (GstBaseSink * base, GstCaps * filter) caps_string = gst_caps_to_string (sink->cached_caps); GST_DEBUG_OBJECT (sink, "using cached caps: %s", caps_string); g_free (caps_string); + if (filter) + return gst_caps_intersect_full (sink->cached_caps, filter, + GST_CAPS_INTERSECT_FIRST); return gst_caps_ref (sink->cached_caps); } -- 2.7.4