Unified Plan SDP format in WebRTC

Until recently a customised or property extension could signal multiple media streams within an m-section of an SDP and experiment with media-level “msid” (Media Stream Identifier ) attribute used to associate RTP streams that are described in different media descriptions with the same MediaStreams. However, with the transition to a unified plan, they will experience breaking changes.

The previous SDP format implementation called “planB” was transitioned to “unified plan” in 2019.

Who it does effect ?

  • Uses various media tracks within m line in SDP such as for video stream and screen sharing simultaneously
  • Munges SDP, uses MCUs or SFUs
  • used track-based APIs addTrack, removeTrack, and sender.replaceTrack or legacy addstream removeStream exposed senders and receivers to edit tracks and their encoding parameters

Who it does not affect ?

  • This does not affect any application which has only single audio and video track.
 { iceServers: [], iceTransportPolicy: all, bundlePolicy: balanced, rtcpMuxPolicy: require, iceCandidatePoolSize: 0, sdpSemantics: "unified-plan" },

Plan B vs Unified Pan

Multiple media stream may be required for cases such as video and screen share stream in same SDP or in specific cases of SFU.

This implementation in Plan B will result in one “m=” line of SDP being used for video and audio. While within the video m= section multiple “a=ssrc” lines are listed for multiple media tracks.

In Unified Plan, every single media track is assigned to a separate “m=” section. Hence for video and screen sharing simultaneously two m sections will be created.

Interoperability between unified plan and plan B

A mismatch in SDP (between Plan B and Unified Plan) usually results :-

  1. only Unified Plan client receives an offer generated by a Plan B client – the Unified Plan client must reject the offer with a failed setRemoteDescription() error.
  2. only Plan B client receives an offer generated by a Unified Plan client – only first track in every “m=” section is used and other tracks are ignored

Reference :

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.