summaryrefslogtreecommitdiff
path: root/gst/playback/gstsubtitleoverlay.c
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian.droege@collabora.co.uk>2013-05-14 10:06:40 +0200
committerSebastian Dröge <sebastian.droege@collabora.co.uk>2013-05-14 10:07:44 +0200
commit450a47c0a515cc51a1d9171f702940903ce11c34 (patch)
treea1e0ce3200efc474a766a8afd2223189a162383e /gst/playback/gstsubtitleoverlay.c
parent94b7ae776799a11351760752dc95853b08bb19d6 (diff)
playback: Use subset checks instead of intersection
https://bugzilla.gnome.org/show_bug.cgi?id=700272
Diffstat (limited to 'gst/playback/gstsubtitleoverlay.c')
-rw-r--r--gst/playback/gstsubtitleoverlay.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/gst/playback/gstsubtitleoverlay.c b/gst/playback/gstsubtitleoverlay.c
index 70af107b2..64e9adefd 100644
--- a/gst/playback/gstsubtitleoverlay.c
+++ b/gst/playback/gstsubtitleoverlay.c
@@ -441,7 +441,7 @@ static gboolean
check_factory_for_caps (GstElementFactory * factory, const GstCaps * caps)
{
GstCaps *fcaps = _get_sub_caps (factory);
- gboolean ret = (fcaps) ? gst_caps_can_intersect (fcaps, caps) : FALSE;
+ gboolean ret = (fcaps) ? gst_caps_is_subset (caps, fcaps) : FALSE;
if (fcaps)
gst_caps_unref (fcaps);
@@ -999,7 +999,7 @@ _link_renderer (GstSubtitleOverlay * self, GstElement * renderer,
} else { /* No video pad */
GstCaps *allowed_caps, *video_caps = NULL;
GstPad *video_peer;
- gboolean can_intersect = FALSE;
+ gboolean is_subset = FALSE;
video_peer = gst_pad_get_peer (self->video_sinkpad);
if (video_peer) {
@@ -1019,7 +1019,7 @@ _link_renderer (GstSubtitleOverlay * self, GstElement * renderer,
gst_object_unref (sink);
if (allowed_caps && video_caps)
- can_intersect = gst_caps_can_intersect (allowed_caps, video_caps);
+ is_subset = gst_caps_is_subset (video_caps, allowed_caps);
if (allowed_caps)
gst_caps_unref (allowed_caps);
@@ -1027,7 +1027,7 @@ _link_renderer (GstSubtitleOverlay * self, GstElement * renderer,
if (video_caps)
gst_caps_unref (video_caps);
- if (G_UNLIKELY (!can_intersect)) {
+ if (G_UNLIKELY (!is_subset)) {
GST_WARNING_OBJECT (self, "Renderer with custom caps is not "
"compatible with video stream");
return FALSE;