Hello everyone,
I’m exploring an RTP processing setup and I have a question about GStreamer’s capabilities.
Is it possible for GStreamer to receive multiple independent RTP streams on the same UDP port and still be able to distinguish and process each stream separately (e.g., for decoding, mixing, or composition)?
If so, how would GStreamer differentiate between the different senders or SSRCs?
And what would the recommended pipeline or elements be for handling multiple RTP sources arriving on the same port?
Any guidance or examples would be greatly appreciated.
Yes, GStreamer supports that, and it’s very common as well (“RTP bundling”).
There are low-level elements such as rtpptdemux and rtpssrcdemux that can extract the individual streams.
All of this is handled automatically in the rtpbin element (or rtprecv for the new Rust implementation which isn’t fully on par feature-wise with rtpbin yet, but may suffice for your use case).
Is it possible ? Generally yes most media / streaming apps see any difference in IP src/dst addr and port (and optionally RTP payload) as a different stream. Typically an internal session Id is created using this info as a hash key. SSRCs are typically not included in the key as they can change on-the-fly per RFC8108 (a practical example is cell tower handoff of voice calls).
Specifically in GStreamer, in the rtpbin description the key text is “Access to the internal statistics of rtpbin is provided with the get-internal-session property. This action signal gives access to the RTPSession object which further provides action signals to retrieve the internal source and other sources”. I’m not sure but available session info should include a list of all SSRCs currently associated with the session.
If this is doesn’t solve your application need then possibly I can help; feel free to DM me.