NullVoxPopuli
NullVoxPopuli

Reputation: 65093

How can I programmatically mux multiple RTP audio streams together?

I have several RTP streams coming to from the network, and since RTP can only handle one stream in each direction, I need to able to merge a couple to send back to another client (could be one that is already sending an RTP stream, or not... that part isn't important).

My guess is that there is some algorithm for mixing audio bytes.

RTP Stream 1 ---------------------
                                   \_____________________ (1 MUXED 2) RTP Stream Out
                                   /
RTP Stream 2 ---------------------

Upvotes: 1

Views: 2320

Answers (2)

Boris
Boris

Reputation: 1437

I think you are talking about VoIP conference. mediastreamer2 library I think supports conference filter.

Upvotes: 1

Neera
Neera

Reputation: 1587

There is an IETF draft for RTP stream Muxing which might help you the link is here http://www.cs.columbia.edu/~hgs/rtp/drafts/draft-tanigawa-rtp-multiplex-01.txt

In case you want to use only one stream, then perhaps send data from multiple streams as different channles this link gives an overview how Audio channels are multiplexed in WAV files. You can adopt similar strategy

Upvotes: 1

Related Questions