multiple streams on one page using WebRTC

284 views
Skip to first unread message

Olga Khylkouskaya

unread,
Oct 19, 2016, 8:26:43 PM10/19/16
to meetecho-janus
Hello, 

We are moving away from flash, especially for Chrome and I'm implementing WebRTC. 
I made things work for one video from our server(ffmpeg producer to rtp and then to Janus). But I need to implement it for multiple videos on one page.
I create video object(if necessary) in the function: onremotestream: function (stream)
However there is no information in the stream to relate it to create request:
  "request": "create",
   "audio": false,
   "description": "93Ik0w0G8VYOr7WTAXHNtO2XC",
   "id": 3,
   "name": "93Ik0w0G8VYOr7WTAXHNtO2XC",
   "type": "rtp",
   "video": true,
   "videofmtp": "level-asymmetry-allowed=1;profile-level-id=42e01f;packetization-mode=1",
   "videoport": 5026,
   "videopt": 96,
   "videortpmap": "H264/90000"

Is there a way to have id(3 from above) in either:
  1. janusStream.getVideoTracks()[0]MediaStreamTrack or
  1. janusStreamMediaStream - janusStream.id ("janus")
  2. instead of hardcoded string there janus or janussv0

If not can you please direct me to the source code where it can be added and I'll submit a pull request.

Thanks, 
Olga Khylkouskaya.



Lorenzo Miniero

unread,
Oct 20, 2016, 7:55:41 AM10/20/16
to meetecho-janus
You can only have a single PeerConnection per handle, so there's no need for such a mapping. It can be done within the application.

L.
Message has been deleted

Olga Khylkouskaya

unread,
Oct 20, 2016, 11:48:33 AM10/20/16
to meetecho-janus
Thank you Lorenzo, 

I'll create multiple streaming handles then.
Reply all
Reply to author
Forward
0 new messages