rtc-io / rtc-quickconnect

An opinionated approach to creating WebRTC apps (both media and datachannels supported)
Apache License 2.0
186 stars 43 forks source link

Add detection of SDP semantics #100

Closed nathanoehlman closed 5 years ago

nathanoehlman commented 6 years ago

With the support in Chrome for Unified Plan, and the upcoming switch in M72 to use it by default, there comes a need to be able to specify what SDP semantics a peer connection should be created with.

This adds a (loose) matching system that allows automatic identification of the SDP semantics that should be used when interoperating between browsers.

It also adds the ability to pass in a sdpSemantics option to the quickconnect instance to override the detected semantic (in the event you want to force a semantic). As the sdpSemantic option is only supported by Chrome, in browsers that do not support it, it is safely ignored.