multiple media connections per peer?

417 views
Skip to first unread message

Paul-Emile Veuve

unread,
Dec 9, 2014, 11:39:33 AM12/9/14
to pee...@googlegroups.com
   hi all,

I am wondering if it is possible to have multiple media connections per peer.
Basically, I would like to run peer.call(id, stream) twice, one for the webcam video stream, another for a screensharing stream.

I have read somewhere Firefox supports one audio and video stream per peer connection only. 
So my guess is that it would work for Chrome only, but I prefer having confirmation.

If my understanding is correct, then is it possible to open 2 peer connections between browsers ?


thanks,


Paul-Emile

Paul-Emile Veuve

unread,
Dec 10, 2014, 9:36:09 AM12/10/14
to pee...@googlegroups.com
I see, what I actually need is the change: Multiple streams per MediaConnection #132

It allows us to send multiple streams per mediaConnection, but it's not pushed in Github repo yet. 
Does someone knows if/when it will be available, or why it is blocked?
I would prefer to stick to the official release rather than having to merge my changes with each new versions.

Michelle Bu

unread,
Dec 10, 2014, 3:56:30 PM12/10/14
to Paul-Emile Veuve, peerjs
Hm, you should already be able to do this! That issue has little to do
with being able to open more than one stream between browsers, but
more to do with changing the stream that the connection is streaming
once it's been created.
Michelle

Paul-Emile Veuve

unread,
Dec 11, 2014, 4:56:52 AM12/11/14
to pee...@googlegroups.com, pev...@gmail.com, miche...@berkeley.edu
Either I wasn't clear enough, or I don't get you...
I would like to stream a video and share a screen/window at the same time.
If I change the stream (but how to do that?) once the connection is opened, I suppose the former stream will be closed, no?
Basically, I would like to call RTCPeerConnection.addStream() twice.

Please enlight me! :)

Michelle Bu

unread,
Dec 11, 2014, 2:19:33 PM12/11/14
to Paul-Emile Veuve, peerjs
You can Peer.call twice with your two streams.
Michelle

Paul-Emile Veuve

unread,
Dec 11, 2014, 5:44:53 PM12/11/14
to pee...@googlegroups.com, pev...@gmail.com, miche...@berkeley.edu
OK, thanks, I will try that.

Paul-Emile Veuve

unread,
Dec 12, 2014, 7:44:21 AM12/12/14
to pee...@googlegroups.com, pev...@gmail.com, miche...@berkeley.edu
and it works, great!
Reply all
Reply to author
Forward
0 new messages