summaryrefslogtreecommitdiffstats
path: root/gst/rtpmanager/rtpsession.h
diff options
context:
space:
mode:
authorYouness Alaoui <youness.alaoui@collabora.co.uk>2008-01-11 16:45:57 +0000
committerWim Taymans <wim.taymans@gmail.com>2008-01-11 16:45:57 +0000
commit2e0d1efb0ea5863bfccbf40bf96fc6ef15ad8ae9 (patch)
treee5e9d519b7540d7a306d1782213721d1c345d002 /gst/rtpmanager/rtpsession.h
parent2e75ee53cd4c110337c1063dcaa29183d499f9c6 (diff)
downloadgst-plugins-bad-2e0d1efb0ea5863bfccbf40bf96fc6ef15ad8ae9.tar.gz
gst-plugins-bad-2e0d1efb0ea5863bfccbf40bf96fc6ef15ad8ae9.tar.bz2
gst-plugins-bad-2e0d1efb0ea5863bfccbf40bf96fc6ef15ad8ae9.zip
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/rtpsession.h')
-rw-r--r--gst/rtpmanager/rtpsession.h35
1 files changed, 29 insertions, 6 deletions
diff --git a/gst/rtpmanager/rtpsession.h b/gst/rtpmanager/rtpsession.h
index 12dd1603..59703300 100644
--- a/gst/rtpmanager/rtpsession.h
+++ b/gst/rtpmanager/rtpsession.h
@@ -85,10 +85,10 @@ typedef GstFlowReturn (*RTPSessionSendRTCP) (RTPSession *sess, RTPSource *src, G
* RTPSessionSyncRTCP:
* @sess: an #RTPSession
* @src: the #RTPSource
- * @buffer: the RTCP buffer ready for sending
+ * @buffer: the RTCP buffer ready for synchronisation
* @user_data: user data specified when registering
*
- * This callback will be called when @sess has and SR @buffer ready for doing
+ * This callback will be called when @sess has an SR @buffer ready for doing
* synchronisation between streams.
*
* Returns: a #GstFlowReturn.
@@ -133,8 +133,8 @@ typedef void (*RTPSessionReconsider) (RTPSession *sess, gpointer user_data);
typedef struct {
RTPSessionProcessRTP process_rtp;
RTPSessionSendRTP send_rtp;
- RTPSessionSendRTCP send_rtcp;
RTPSessionSyncRTCP sync_rtcp;
+ RTPSessionSendRTCP send_rtcp;
RTPSessionClockRate clock_rate;
RTPSessionReconsider reconsider;
} RTPSessionCallbacks;
@@ -177,8 +177,13 @@ struct _RTPSession {
gchar *bye_reason;
gboolean sent_bye;
- RTPSessionCallbacks callbacks;
- gpointer user_data;
+ RTPSessionCallbacks callbacks;
+ gpointer process_rtp_user_data;
+ gpointer send_rtp_user_data;
+ gpointer send_rtcp_user_data;
+ gpointer sync_rtcp_user_data;
+ gpointer clock_rate_user_data;
+ gpointer reconsider_user_data;
RTPSessionStats stats;
@@ -211,9 +216,27 @@ GType rtp_session_get_type (void);
/* create and configure */
RTPSession* rtp_session_new (void);
-void rtp_session_set_callbacks (RTPSession *sess,
+void rtp_session_set_callbacks (RTPSession *sess,
RTPSessionCallbacks *callbacks,
gpointer user_data);
+void rtp_session_set_process_rtp_callback (RTPSession * sess,
+ RTPSessionProcessRTP callback,
+ gpointer user_data);
+void rtp_session_set_send_rtp_callback (RTPSession * sess,
+ RTPSessionSendRTP callback,
+ gpointer user_data);
+void rtp_session_set_send_rtcp_callback (RTPSession * sess,
+ RTPSessionSendRTCP callback,
+ gpointer user_data);
+void rtp_session_set_sync_rtcp_callback (RTPSession * sess,
+ RTPSessionSyncRTCP callback,
+ gpointer user_data);
+void rtp_session_set_clock_rate_callback (RTPSession * sess,
+ RTPSessionClockRate callback,
+ gpointer user_data);
+void rtp_session_set_reconsider_callback (RTPSession * sess,
+ RTPSessionReconsider callback,
+ gpointer user_data);
void rtp_session_set_bandwidth (RTPSession *sess, gdouble bandwidth);
gdouble rtp_session_get_bandwidth (RTPSession *sess);
void rtp_session_set_rtcp_fraction (RTPSession *sess, gdouble fraction);