summaryrefslogtreecommitdiffstats
path: root/gst/rtpmanager/gstrtpsession.c
diff options
context:
space:
mode:
authorYouness Alaoui <youness.alaoui@collabora.co.uk>2008-01-11 16:45:57 +0000
committerTim-Philipp Müller <tim.muller@collabora.co.uk>2009-08-11 02:30:33 +0100
commit03d9faf5fa8e27f433d5c247801ec7257a7428f7 (patch)
treef2dd93f2c748748b31f3af72d8e2bd59268a0d32 /gst/rtpmanager/gstrtpsession.c
parentc6d892420a848ff3d0fcfd73ff4f176a966c77a4 (diff)
gst/rtpmanager/: Make it possible to use different user_data for each of the callbacks.
Original commit message from CVS: Patch by: Youness Alaoui <youness dot alaoui at collabora dot co dot uk> * gst/rtpmanager/gstrtpsession.c: (gst_rtp_session_clock_rate): * gst/rtpmanager/rtpsession.c: (rtp_session_set_callbacks), (rtp_session_set_process_rtp_callback), (rtp_session_set_send_rtp_callback), (rtp_session_set_send_rtcp_callback), (rtp_session_set_sync_rtcp_callback), (rtp_session_set_clock_rate_callback), (rtp_session_set_reconsider_callback), (source_push_rtp), (source_clock_rate), (rtp_session_process_bye), (rtp_session_process_rtcp), (rtp_session_send_bye), (rtp_session_on_timeout): * gst/rtpmanager/rtpsession.h: Make it possible to use different user_data for each of the callbacks. Fixes #508587.
Diffstat (limited to 'gst/rtpmanager/gstrtpsession.c')
-rw-r--r--gst/rtpmanager/gstrtpsession.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/gst/rtpmanager/gstrtpsession.c b/gst/rtpmanager/gstrtpsession.c
index 790a0a1d..ffdaf901 100644
--- a/gst/rtpmanager/gstrtpsession.c
+++ b/gst/rtpmanager/gstrtpsession.c
@@ -286,8 +286,8 @@ static void gst_rtp_session_reconsider (RTPSession * sess, gpointer user_data);
static RTPSessionCallbacks callbacks = {
gst_rtp_session_process_rtp,
gst_rtp_session_send_rtp,
- gst_rtp_session_send_rtcp,
gst_rtp_session_sync_rtcp,
+ gst_rtp_session_send_rtcp,
gst_rtp_session_clock_rate,
gst_rtp_session_reconsider
};
@@ -1188,6 +1188,8 @@ gst_rtp_session_clock_rate (RTPSession * sess, guint8 payload,
GST_RTP_SESSION_LOCK (rtpsession);
ipayload = payload; /* make compiler happy */
caps = g_hash_table_lookup (priv->ptmap, GINT_TO_POINTER (ipayload));
+ /* TODO : check if we should really goto done. This will return -1
+ * instead of the clock rate of the caps we just found! */
if (caps)
goto done;
@@ -1208,6 +1210,7 @@ gst_rtp_session_clock_rate (RTPSession * sess, guint8 payload,
gst_rtp_session_cache_caps (rtpsession, caps);
+ /* TODO : This is where we should 'goto' */
s = gst_caps_get_structure (caps, 0);
if (!gst_structure_get_int (s, "clock-rate", &result))
goto no_clock_rate;