Hi all,
first of all, sorry for posting this here: I tried posting on the mozilla.dev.media group, but almost three weeks have passed without a reply, so I guess I won't get any indication there on what may be going wrong. Since I assume most of you will be doing tests with both Chrome and Firefox, I hope I'll get luckier here!
I'm encountering a few issues in getting Firefox to work with my Janus gateway in a couple of scenarios. Specifically, when I setup a video MCU, Chrome users get video from everybody participating (other Chrome and Firefox users), while Firefox users only get it from other Firefox users.
Just as a heads-up on how the video MCU scenario works, each user has N+1 peer connections set up with the gateway: one is sendonly and used to send the peer's media to the gateway, and then there are N recvonly streams where the peer can receive each other individual participants contributions instead. As I anticipated, the outgoing stream in principle seems to be working, as both Chrome and Firefox instances are able to playout what Firefox is sending, so no problem there apparently.
I should also point out that other scenarios handled by my gateway work fine with Firefox instead, meaning that DTLS, ICE, SRTP and so on should not be the issue. For instance, the simple video call scenario works fine instead, with either Chrome or Firefox being the caller or the callee, which means that it's not a problem with who is generating the call and who is receiving it.
That said, looking at the about:webrtc logs, I can see that for the PeerConnections that don't work I'm getting statistics that look like these:
RTP statistics
inbound_rtp_audio_1
A/V sync: 0 ms Jitter-buffer delay: 60 ms
Local: 13:09:35 GMT+0200 (CEST) inboundrtp SSRC: 12345 Received: 670 packets (28.79 Kb) Lost: 0 Jitter: 0.003
inbound_rtp_video_2
Local: 13:09:35 GMT+0200 (CEST) inboundrtp SSRC: 0 Received: 758 packets (502.82 Kb) Lost: undefined Jitter: undefined
Both the ICE and DTLS steps are correctly completed. I guess that the 0 SSRC is the root cause of the issue there. For some reason, Firefox has no view of the SSRC the gateway is using for video. The SSRC is there in the SDP, and is correctly set in both RTP and RTCP packets, and frames are definitely being received, as the sample log above seems to confirm. As a related issue, Firefox ignores FIR requests too, I guess for the same reason. What's weird is that the receiving part works fine if the related sender is another Firefox instance (even though it may appear after a while as FIR messages don't work).
Investigating the logs I also found some lines like this:
-260211904[f751b500]: [Socket Thread|WebrtcVideoSessionConduit] VideoConduit.cpp:959: Error: ReceivedRTCPPacket when not receiving
that apparently indicate that Firefox is discarding RTCP packets for the sendonly PeerConnection. Anyway, I don't think that's the cause of the issue, otherwise Firefox clients wouldn't be able to get the video coming from other Firefox participants either.
Could you help me understand what I may be doing wrong? As far as you know, is there any specific step that may be missing that Firefox needs to have a valid SSRC? You can test the scenario yourself using the public demo page we have here:
http://janus.conf.meetecho.com/videomcutest.html or, if you prefer (it's open source, after all), installing the gateway on one of your machines and test locally.
Let me know if there's any other info you may need of me to help me finally tackle this issue.
Thanks!
Lorenzo