summaryrefslogtreecommitdiff
path: root/extra/farstream-0.1/intersect-instead-of-merge.patch
blob: 734e1538361fdf7371e2beba9712dabcea5da626 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
diff --git a/gst/fsrtpconference/fs-rtp-discover-codecs.c b/gst/fsrtpconference/fs-rtp-discover-codecs.c
index d128e84..3521580 100644
--- a/gst/fsrtpconference/fs-rtp-discover-codecs.c
+++ b/gst/fsrtpconference/fs-rtp-discover-codecs.c
@@ -1110,11 +1110,8 @@ compare_media_caps (gconstpointer a, gconstpointer b)
 }
 
 static gint
-compare_rtp_caps (gconstpointer a, gconstpointer b)
+compare_rtp_caps (CodecCap *element, GstCaps *c_caps)
 {
-  CodecCap *element = (CodecCap *)a;
-  GstCaps *c_caps = (GstCaps *)b;
-
   return !gst_caps_can_intersect (element->rtp_caps, c_caps);
 }
 
@@ -1226,7 +1223,7 @@ create_codec_cap_list (GstElementFactory *factory,
         if (rtp_caps) {
           if (entry->rtp_caps) {
             GstCaps *new_rtp_caps;
-            new_rtp_caps = gst_caps_union (rtp_caps, entry->rtp_caps);
+            new_rtp_caps = gst_caps_intersect (rtp_caps, entry->rtp_caps);
             gst_caps_unref (entry->rtp_caps);
             entry->rtp_caps = new_rtp_caps;
           } else {