GNOME Bugzilla – Bug 703016
gst-rtsp-server: check client rtp session handling
Last modified: 2014-02-25 22:28:24 UTC
It would be good to know if a client handles a given RTP session. For example, in the RTP session signal callbacks (e.g. on-ssrc-active) it is difficult to find out which RTSP client this session belongs to.
Created attachment 247692 [details] [review] check rtp session handling helpers Not sure if this is the right (or best) way to do this. Actually it is only a pointer equality test, but it comes in handy if you want to do the correlation between an RTSP client and a GstRTSPStream or RTP session.
Created attachment 247693 [details] [review] check rtp session handling helpers Last one had the wrong commit message.
Multiple clients can all use the same session (when shared), if you have a client, you can find the sessions that it uses by following the media it handles and then the streams of the media. Your patch uses gst_rtsp_client_get_uri() with is not exactly what you want to do. the uri property is an internal property to manage the last cached media object.
Here's a more generic method to iterate the sessions of a client. You can then get to the media and streams etc. commit ffd4b1aaf11bd2a9755e83768f018640a9e7f19f Author: Wim Taymans <wim.taymans@collabora.co.uk> Date: Wed Jun 26 17:18:33 2013 +0200 client: add method to filter managed sessions Add a method to filter the sessions managed by this client connection. See https://bugzilla.gnome.org/show_bug.cgi?id=703016
Nice, thanks! Actually I have a reference of a client and in the RTP session on-ssrc-active signal I want to know the corresponding client. There is no direct way to do this, AFAIK. But with this function, I can iterate through all sessions, media, streams and transport and can check the SSRC from the transport. However, I just filed a bug 703158 with, I think, a faster way to achieve this.
This is already done, so marking it as fixed.