w3c/webrtc-pc

RTCPeerConnection.iceGatheringState is updated differently for datachannel than audio/video

Opened this issue · 0 comments

From https://w3c.github.io/webrtc-pc/#rtcicegatheringstate-enum

The set of transports considered is the one presently referenced by the RTCPeerConnection's set of transceivers and the RTCPeerConnection's [[SctpTransport]] internal slot if not null.

[[SctpTransport]] is set when the answer is set:

https://w3c.github.io/webrtc-pc/#ref-for-dfn-sctptransport-4

Whereas transports are set on senders/receivers in sLD:

https://w3c.github.io/webrtc-pc/#ref-for-dfn-sendertransport-2
https://w3c.github.io/webrtc-pc/#ref-for-dfn-receivertransport-2

This means that we do not see icegatheringstatechange events/updates until we reach stable if we have a datachannel only, but we get those events/updates in have-local-offer if that datachannel is bundled with an audio or video msection!