SlideShare a Scribd company logo
1 of 54
Download to read offline
Audio redundancy in WebRTC and Janus via RED
Lorenzo Miniero
ClueCon – Chicago, IL, USA (kinda!)
October 27th 2021
Who am I?
Lorenzo Miniero
• Ph.D @ UniNA
• Chairman @ Meetecho
• Main author of Janus®
Contacts and info
• lorenzo@meetecho.com
• https://twitter.com/elminiero
• https://www.slideshare.net/LorenzoMiniero
• https://soundcloud.com/lminiero
• https://lminiero.bandcamp.com
Just a few words on Meetecho
• Co-founded in 2009 as an academic spin-off
• University research efforts brought to the market
• Completely independent from the University
• Focus on real-time multimedia applications
• Strong perspective on standardization and open source
• Several activities
• Consulting services
• Commercial support and Janus licenses
• Streaming of live events (IETF, ACM, etc.)
• Proudly brewed in sunny Napoli, Italy
Home Sweet Home!
Remember Janus?
Janus
General purpose, open source WebRTC server
• https://github.com/meetecho/janus-gateway
• Demos and documentation: https://janus.conf.meetecho.com
• Community: https://groups.google.com/forum/#!forum/meetecho-janus
Modular architecture
Modular architecture
A ton of scenarios done today with Janus!
• SIP and RTSP gatewaying
• WebRTC-based call/contact centers
• Conferencing & collaboration
• E-learning & webinars
• Cloud platforms
• Media production
• Broadcasting & Gaming
• Identity verification
• Internet of Things
• Augmented/Virtual Reality
• ...and more!
It’s not just about video!
• Video obviously takes the lion’s share, most of the times
• Pretty much ubiquitous
• Most use cases assume video, one way or another
• It’s not the only thing that matters, though
• We still need to communicate, somehow
• Audio (and data) can be just as important, if not more
• Some applications even focus JUST on audio!
• ... and not only call/contact centers, PBX, or legacy infrastructures
It’s not just about video!
• Video obviously takes the lion’s share, most of the times
• Pretty much ubiquitous
• Most use cases assume video, one way or another
• It’s not the only thing that matters, though
• We still need to communicate, somehow
• Audio (and data) can be just as important, if not more
• Some applications even focus JUST on audio!
• ... and not only call/contact centers, PBX, or legacy infrastructures
It’s not just about video!
• Video obviously takes the lion’s share, most of the times
• Pretty much ubiquitous
• Most use cases assume video, one way or another
• It’s not the only thing that matters, though
• We still need to communicate, somehow
• Audio (and data) can be just as important, if not more
• Some applications even focus JUST on audio!
• ... and not only call/contact centers, PBX, or legacy infrastructures
A relevant example: Clubhouse
Another relevant example: Twitter Spaces
You didn’t hear it from me...
“Can WebRTC help musicians?”
https://fosdem.org/2021/schedule/event/webrtc_musicians/
WebRTC and audio
• A couple of mandatory-to-implement codecs
• Opus + G.711
• G.711 just there as a fallback (and legacy interopability)
• Opus FTW!
• High quality audio codec designed for the Internet
• Very flexible in sampling rates, bitrates, etc.
• Support for stereo, and different “profiles” for voice/music
• Surround availble too, on an experimental basis (multiopus)
• A few interesting “tools”
• Audio levels RTP extension (VAD)
• Opus inband Forward Error Correction (FEC)
• Opus Discontinuous transmission (DTX)
WebRTC and audio
• A couple of mandatory-to-implement codecs
• Opus + G.711
• G.711 just there as a fallback (and legacy interopability)
• Opus FTW!
• High quality audio codec designed for the Internet
• Very flexible in sampling rates, bitrates, etc.
• Support for stereo, and different “profiles” for voice/music
• Surround availble too, on an experimental basis (multiopus)
• A few interesting “tools”
• Audio levels RTP extension (VAD)
• Opus inband Forward Error Correction (FEC)
• Opus Discontinuous transmission (DTX)
WebRTC and audio
• A couple of mandatory-to-implement codecs
• Opus + G.711
• G.711 just there as a fallback (and legacy interopability)
• Opus FTW!
• High quality audio codec designed for the Internet
• Very flexible in sampling rates, bitrates, etc.
• Support for stereo, and different “profiles” for voice/music
• Surround availble too, on an experimental basis (multiopus)
• A few interesting “tools”
• Audio levels RTP extension (VAD)
• Opus inband Forward Error Correction (FEC)
• Opus Discontinuous transmission (DTX)
Audio-only: SFU or MCU?
• SFUs ideal to just relay media
• No mixing/transcoding to worry about −→ less CPU on server, less delay
• More streams to distribute −→ more bandwidth needed
• Different streams −→ more control on UI
• MCUs ideal to just mix media
• Mixing/transcoding taking place −→ more CPU on server, more delay
• Just one stream to distribute −→ bandwidth constant
• Single output stream −→ UI rendering constrained
• Sometimes it makes sense to use them both!
• Use SFU where applicable (e.g., video, plenty of bandwidth)
• Use MCU to complement (e.g., audio, lower power devices)
• Besides, an MCU can mix SFU streams to broadcast to a CDN!
Audio-only: SFU or MCU?
• SFUs ideal to just relay media
• No mixing/transcoding to worry about −→ less CPU on server, less delay
• More streams to distribute −→ more bandwidth needed
• Different streams −→ more control on UI
• MCUs ideal to just mix media
• Mixing/transcoding taking place −→ more CPU on server, more delay
• Just one stream to distribute −→ bandwidth constant
• Single output stream −→ UI rendering constrained
• Sometimes it makes sense to use them both!
• Use SFU where applicable (e.g., video, plenty of bandwidth)
• Use MCU to complement (e.g., audio, lower power devices)
• Besides, an MCU can mix SFU streams to broadcast to a CDN!
Audio-only: SFU or MCU?
• SFUs ideal to just relay media
• No mixing/transcoding to worry about −→ less CPU on server, less delay
• More streams to distribute −→ more bandwidth needed
• Different streams −→ more control on UI
• MCUs ideal to just mix media
• Mixing/transcoding taking place −→ more CPU on server, more delay
• Just one stream to distribute −→ bandwidth constant
• Single output stream −→ UI rendering constrained
• Sometimes it makes sense to use them both!
• Use SFU where applicable (e.g., video, plenty of bandwidth)
• Use MCU to complement (e.g., audio, lower power devices)
• Besides, an MCU can mix SFU streams to broadcast to a CDN!
We do use both in our Virtual Event Platform!
https://commcon.xyz/session/turning-live-events-to-virtual-with-janus
Many efforts focused on audio in Janus, recently
• Modular nature of Janus encourages new functionality
• Not necessarily in new plugins
• VideoRoom, AudioBridge, Streaming plugins can all benefit
• Several activities done, started or planned to enhance audio experience
• Mostly in AudioBridge... (due to the nature of the plugin)
• ... but some features actually available to all plugins!
• Many coming from requirements for our Virtual Event Platform
• But we like to experiment as well!
• Main topic of a recent talk @ Open Source World
• https://www.slideshare.net/LorenzoMiniero/janus-audio-open-source-world
Many efforts focused on audio in Janus, recently
• Modular nature of Janus encourages new functionality
• Not necessarily in new plugins
• VideoRoom, AudioBridge, Streaming plugins can all benefit
• Several activities done, started or planned to enhance audio experience
• Mostly in AudioBridge... (due to the nature of the plugin)
• ... but some features actually available to all plugins!
• Many coming from requirements for our Virtual Event Platform
• But we like to experiment as well!
• Main topic of a recent talk @ Open Source World
• https://www.slideshare.net/LorenzoMiniero/janus-audio-open-source-world
Many efforts focused on audio in Janus, recently
• Modular nature of Janus encourages new functionality
• Not necessarily in new plugins
• VideoRoom, AudioBridge, Streaming plugins can all benefit
• Several activities done, started or planned to enhance audio experience
• Mostly in AudioBridge... (due to the nature of the plugin)
• ... but some features actually available to all plugins!
• Many coming from requirements for our Virtual Event Platform
• But we like to experiment as well!
• Main topic of a recent talk @ Open Source World
• https://www.slideshare.net/LorenzoMiniero/janus-audio-open-source-world
Many efforts focused on audio in Janus, recently
• Modular nature of Janus encourages new functionality
• Not necessarily in new plugins
• VideoRoom, AudioBridge, Streaming plugins can all benefit
• Several activities done, started or planned to enhance audio experience
• Mostly in AudioBridge... (due to the nature of the plugin)
• ... but some features actually available to all plugins!
• Many coming from requirements for our Virtual Event Platform
• But we like to experiment as well!
• Main topic of a recent talk @ Open Source World
• https://www.slideshare.net/LorenzoMiniero/janus-audio-open-source-world
Audio redundancy via RED
• Old RTP payload format for Redundant Audio Data (RED)
• https://datatracker.ietf.org/doc/html/rfc2198
• Recently added to Chrome on an experimental basis
• https://bugs.chromium.org/p/webrtc/issues/detail?id=11640
• https://webrtchacks.com/red-improving-audio-quality-with-redundancy/
• https://webrtchacks.com/implementing-redundant-audio-on-an-sfu/
• Basically a simple way to group multiple audio frames in a single RTP packet
• Current audio frame + one or more previously sent frames
• Allows recipient to easily recover lost packets at the cost of more bandwidth
Audio redundancy via RED
• Old RTP payload format for Redundant Audio Data (RED)
• https://datatracker.ietf.org/doc/html/rfc2198
• Recently added to Chrome on an experimental basis
• https://bugs.chromium.org/p/webrtc/issues/detail?id=11640
• https://webrtchacks.com/red-improving-audio-quality-with-redundancy/
• https://webrtchacks.com/implementing-redundant-audio-on-an-sfu/
• Basically a simple way to group multiple audio frames in a single RTP packet
• Current audio frame + one or more previously sent frames
• Allows recipient to easily recover lost packets at the cost of more bandwidth
Audio redundancy via RED
• Old RTP payload format for Redundant Audio Data (RED)
• https://datatracker.ietf.org/doc/html/rfc2198
• Recently added to Chrome on an experimental basis
• https://bugs.chromium.org/p/webrtc/issues/detail?id=11640
• https://webrtchacks.com/red-improving-audio-quality-with-redundancy/
• https://webrtchacks.com/implementing-redundant-audio-on-an-sfu/
• Basically a simple way to group multiple audio frames in a single RTP packet
• Current audio frame + one or more previously sent frames
• Allows recipient to easily recover lost packets at the cost of more bandwidth
Packet loss without RED
Packet loss without RED
Packet loss with RED
Packet loss with RED
Packet loss with RED
Negotiating RED in SDP
Offer (“I support RED”)
m=audio 9 UDP/TLS/RTP/SAVPF 111 63 103 104 9 0 8 106 105 13 110 112 113 126
[..]
a=rtpmap:111 opus/48000/2
a=rtpmap:63 red/48000/2
a=fmtp:63 111/111
[..]
Answer (”Ok, let’s use RED”)
m=audio 9 UDP/TLS/RTP/SAVPF 63 111
[..]
a=rtpmap:63 red/48000/2
a=rtpmap:111 opus/48000/2
a=fmtp:63 111/111
[..]
Support for audio redundancy via RED in Janus
• Support in Janus needed work in both core and plugins
• Core needed to negotiate RED, and be able to unpack/pack RED
• Plugins needed to be able to do something with the data
• Important to support both endpoints that can do RED, and those who can’t
• RED-to-RED and nonRED-to-nonRED are easy
• In other cases, Janus may have to pack/unpack RED accordingly
• First integration basically done in most plugins
• Still missing in AudioBridge, though
If you want to learn more... (PR in testing phase)
https://www.meetecho.com/blog/opus-red/
Support for audio redundancy via RED in Janus
• Support in Janus needed work in both core and plugins
• Core needed to negotiate RED, and be able to unpack/pack RED
• Plugins needed to be able to do something with the data
• Important to support both endpoints that can do RED, and those who can’t
• RED-to-RED and nonRED-to-nonRED are easy
• In other cases, Janus may have to pack/unpack RED accordingly
• First integration basically done in most plugins
• Still missing in AudioBridge, though
If you want to learn more... (PR in testing phase)
https://www.meetecho.com/blog/opus-red/
Support for audio redundancy via RED in Janus
• Support in Janus needed work in both core and plugins
• Core needed to negotiate RED, and be able to unpack/pack RED
• Plugins needed to be able to do something with the data
• Important to support both endpoints that can do RED, and those who can’t
• RED-to-RED and nonRED-to-nonRED are easy
• In other cases, Janus may have to pack/unpack RED accordingly
• First integration basically done in most plugins
• Still missing in AudioBridge, though
If you want to learn more... (PR in testing phase)
https://www.meetecho.com/blog/opus-red/
Support for audio redundancy via RED in Janus
• Support in Janus needed work in both core and plugins
• Core needed to negotiate RED, and be able to unpack/pack RED
• Plugins needed to be able to do something with the data
• Important to support both endpoints that can do RED, and those who can’t
• RED-to-RED and nonRED-to-nonRED are easy
• In other cases, Janus may have to pack/unpack RED accordingly
• First integration basically done in most plugins
• Still missing in AudioBridge, though
If you want to learn more... (PR in testing phase)
https://www.meetecho.com/blog/opus-red/
non-RED to non-RED
RED to RED
RED to non-RED
non-RED to RED
non-RED to RED
A few challenges to address
• RED to non-RED doesn’t currently take into account redundant info
• If RED packet N-1 is lost, we don’t use packet N to get lost one
• RED packetization code in Janus assumes in-order packets
• May not always be the case (e.g., Streaming plugin and external RTP source)
• RED packetization is shared when doing one-to-many
• New subscribers get redundant info on pre-join audio packets
• Switching subscription in-session briefly mixes redundant info of different sessions
• (N-1 of new stream) != (N-1 of previous stream)
• Discontinuous Transmission (DTX) can cause issues
• Big timestamp jumps can overflow the smaller “timestamp” diff in RED
A few challenges to address
• RED to non-RED doesn’t currently take into account redundant info
• If RED packet N-1 is lost, we don’t use packet N to get lost one
• RED packetization code in Janus assumes in-order packets
• May not always be the case (e.g., Streaming plugin and external RTP source)
• RED packetization is shared when doing one-to-many
• New subscribers get redundant info on pre-join audio packets
• Switching subscription in-session briefly mixes redundant info of different sessions
• (N-1 of new stream) != (N-1 of previous stream)
• Discontinuous Transmission (DTX) can cause issues
• Big timestamp jumps can overflow the smaller “timestamp” diff in RED
A few challenges to address
• RED to non-RED doesn’t currently take into account redundant info
• If RED packet N-1 is lost, we don’t use packet N to get lost one
• RED packetization code in Janus assumes in-order packets
• May not always be the case (e.g., Streaming plugin and external RTP source)
• RED packetization is shared when doing one-to-many
• New subscribers get redundant info on pre-join audio packets
• Switching subscription in-session briefly mixes redundant info of different sessions
• (N-1 of new stream) != (N-1 of previous stream)
• Discontinuous Transmission (DTX) can cause issues
• Big timestamp jumps can overflow the smaller “timestamp” diff in RED
A few challenges to address
• RED to non-RED doesn’t currently take into account redundant info
• If RED packet N-1 is lost, we don’t use packet N to get lost one
• RED packetization code in Janus assumes in-order packets
• May not always be the case (e.g., Streaming plugin and external RTP source)
• RED packetization is shared when doing one-to-many
• New subscribers get redundant info on pre-join audio packets
• Switching subscription in-session briefly mixes redundant info of different sessions
• (N-1 of new stream) != (N-1 of previous stream)
• Discontinuous Transmission (DTX) can cause issues
• Big timestamp jumps can overflow the smaller “timestamp” diff in RED
A few challenges to address
• RED to non-RED doesn’t currently take into account redundant info
• If RED packet N-1 is lost, we don’t use packet N to get lost one
• RED packetization code in Janus assumes in-order packets
• May not always be the case (e.g., Streaming plugin and external RTP source)
• RED packetization is shared when doing one-to-many
• New subscribers get redundant info on pre-join audio packets
• Switching subscription in-session briefly mixes redundant info of different sessions
• (N-1 of new stream) != (N-1 of previous stream)
• Discontinuous Transmission (DTX) can cause issues
• Big timestamp jumps can overflow the smaller “timestamp” diff in RED
What about the impact on bandwidth?
• RED does help with redundancy...
• ... but uses much more bandwidth than usual for audio!
• Initial integration in Chrome used distance of two “generations”
• Each audio packet contains payload of previous two packets
• Bitrate of audio stream increases considerably!
• Less bandwidth available for other streams, e.g., video
• Latest version defaults to a single redundant packet instead
• Overridable with WebRTC-Audio-Red-For-Opus/Enabled-[1-9]/
What about the impact on bandwidth?
• RED does help with redundancy...
• ... but uses much more bandwidth than usual for audio!
• Initial integration in Chrome used distance of two “generations”
• Each audio packet contains payload of previous two packets
• Bitrate of audio stream increases considerably!
• Less bandwidth available for other streams, e.g., video
• Latest version defaults to a single redundant packet instead
• Overridable with WebRTC-Audio-Red-For-Opus/Enabled-[1-9]/
What about the impact on bandwidth?
• RED does help with redundancy...
• ... but uses much more bandwidth than usual for audio!
• Initial integration in Chrome used distance of two “generations”
• Each audio packet contains payload of previous two packets
• Bitrate of audio stream increases considerably!
• Less bandwidth available for other streams, e.g., video
• Latest version defaults to a single redundant packet instead
• Overridable with WebRTC-Audio-Red-For-Opus/Enabled-[1-9]/
What about the impact on bandwidth?
• RED does help with redundancy...
• ... but uses much more bandwidth than usual for audio!
• Initial integration in Chrome used distance of two “generations”
• Each audio packet contains payload of previous two packets
• Bitrate of audio stream increases considerably!
• Less bandwidth available for other streams, e.g., video
• Latest version defaults to a single redundant packet instead
• Overridable with WebRTC-Audio-Red-For-Opus/Enabled-[1-9]/
Thanks! Questions? Comments?
Get in touch!
• https://twitter.com/elminiero
• https://twitter.com/meetecho
• https://www.meetecho.com

More Related Content

What's hot

What's hot (20)

Scaling server side web rtc applications the janus challenge by lorenzo miniero
Scaling server side web rtc applications the janus challenge by lorenzo minieroScaling server side web rtc applications the janus challenge by lorenzo miniero
Scaling server side web rtc applications the janus challenge by lorenzo miniero
 
SIP transfer with Janus/WebRTC @ OpenSIPS 2022
SIP transfer with Janus/WebRTC @ OpenSIPS 2022SIP transfer with Janus/WebRTC @ OpenSIPS 2022
SIP transfer with Janus/WebRTC @ OpenSIPS 2022
 
Architecting your WebRTC application for scalability, Arin Sime
Architecting your WebRTC application for scalability, Arin SimeArchitecting your WebRTC application for scalability, Arin Sime
Architecting your WebRTC application for scalability, Arin Sime
 
Janus SFU cascading @ IIT-RTC 2022
Janus SFU cascading @ IIT-RTC 2022Janus SFU cascading @ IIT-RTC 2022
Janus SFU cascading @ IIT-RTC 2022
 
The challenges of hybrid meetings @ CommCon 2023
The challenges of hybrid meetings @ CommCon 2023The challenges of hybrid meetings @ CommCon 2023
The challenges of hybrid meetings @ CommCon 2023
 
Janus/SIP @ OpenSIPS 2019
Janus/SIP @ OpenSIPS 2019Janus/SIP @ OpenSIPS 2019
Janus/SIP @ OpenSIPS 2019
 
WHIP WebRTC Broadcasting @ FOSDEM 2022
WHIP WebRTC Broadcasting @ FOSDEM 2022WHIP WebRTC Broadcasting @ FOSDEM 2022
WHIP WebRTC Broadcasting @ FOSDEM 2022
 
Welcome to JanusCon! -- Past, Present and Future of Janus
Welcome to JanusCon! -- Past, Present and Future of JanusWelcome to JanusCon! -- Past, Present and Future of Janus
Welcome to JanusCon! -- Past, Present and Future of Janus
 
Spotify: behind the scenes
Spotify: behind the scenesSpotify: behind the scenes
Spotify: behind the scenes
 
Introduction to WebRTC
Introduction to WebRTCIntroduction to WebRTC
Introduction to WebRTC
 
THE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.io
THE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.ioTHE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.io
THE STATE OF OPENTELEMETRY, DOTAN HOROVITS, Logz.io
 
WebRTC on Mobile
WebRTC on MobileWebRTC on Mobile
WebRTC on Mobile
 
Scaling FreeSWITCH Performance
Scaling FreeSWITCH PerformanceScaling FreeSWITCH Performance
Scaling FreeSWITCH Performance
 
SIPREC RTPEngine Media Forking
SIPREC RTPEngine Media ForkingSIPREC RTPEngine Media Forking
SIPREC RTPEngine Media Forking
 
Linux Performance Analysis: New Tools and Old Secrets
Linux Performance Analysis: New Tools and Old SecretsLinux Performance Analysis: New Tools and Old Secrets
Linux Performance Analysis: New Tools and Old Secrets
 
Three Ways Kamailio Can Help Your FreeSWITCH Deployment
Three Ways Kamailio Can Help Your FreeSWITCH DeploymentThree Ways Kamailio Can Help Your FreeSWITCH Deployment
Three Ways Kamailio Can Help Your FreeSWITCH Deployment
 
FreeSWITCH Monitoring
FreeSWITCH MonitoringFreeSWITCH Monitoring
FreeSWITCH Monitoring
 
Vladislav Zavialov – Introduction to GUI programming in Haskell
Vladislav Zavialov – Introduction to GUI programming in HaskellVladislav Zavialov – Introduction to GUI programming in Haskell
Vladislav Zavialov – Introduction to GUI programming in Haskell
 
Spotify: P2P music streaming
Spotify: P2P music streamingSpotify: P2P music streaming
Spotify: P2P music streaming
 
Apache NiFi User Guide
Apache NiFi User GuideApache NiFi User Guide
Apache NiFi User Guide
 

Similar to WebRTC, RED and Janus @ ClueCon21

Web & Apps Design for Mobile Devices
Web & Apps Design for Mobile DevicesWeb & Apps Design for Mobile Devices
Web & Apps Design for Mobile Devices
lerichard
 

Similar to WebRTC, RED and Janus @ ClueCon21 (20)

WebRTC Broadcasting @ TADSummit 2023
WebRTC Broadcasting @ TADSummit 2023WebRTC Broadcasting @ TADSummit 2023
WebRTC Broadcasting @ TADSummit 2023
 
Can WebRTC help musicians? @ FOSDEM 2021
Can WebRTC help musicians? @ FOSDEM 2021Can WebRTC help musicians? @ FOSDEM 2021
Can WebRTC help musicians? @ FOSDEM 2021
 
Write a SocialTV app @ OpenSIPS 2021
Write a SocialTV app @ OpenSIPS 2021Write a SocialTV app @ OpenSIPS 2021
Write a SocialTV app @ OpenSIPS 2021
 
Janus Workshop @ ClueCon 2020
Janus Workshop @ ClueCon 2020Janus Workshop @ ClueCon 2020
Janus Workshop @ ClueCon 2020
 
JamRTC @ Wonder WebRTC unConference
JamRTC @ Wonder WebRTC unConferenceJamRTC @ Wonder WebRTC unConference
JamRTC @ Wonder WebRTC unConference
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Janus @ RTC2017 Beijing
Janus @ RTC2017 BeijingJanus @ RTC2017 Beijing
Janus @ RTC2017 Beijing
 
Janus @ ClueCon 2019
Janus @ ClueCon 2019Janus @ ClueCon 2019
Janus @ ClueCon 2019
 
Vimeo and Open Source (SMPTE Forum 2015)
Vimeo and Open Source (SMPTE Forum 2015)Vimeo and Open Source (SMPTE Forum 2015)
Vimeo and Open Source (SMPTE Forum 2015)
 
WHIP and Janus @ IIT-RTC 2021
WHIP and Janus @ IIT-RTC 2021WHIP and Janus @ IIT-RTC 2021
WHIP and Janus @ IIT-RTC 2021
 
Virtual IETF meetings with WebRTC @ IETF 109 MOPS
Virtual IETF meetings with WebRTC @ IETF 109 MOPSVirtual IETF meetings with WebRTC @ IETF 109 MOPS
Virtual IETF meetings with WebRTC @ IETF 109 MOPS
 
Janus/Asterisk @ Astricon 2017
Janus/Asterisk @ Astricon 2017Janus/Asterisk @ Astricon 2017
Janus/Asterisk @ Astricon 2017
 
FOSS in Broadcast
FOSS in BroadcastFOSS in Broadcast
FOSS in Broadcast
 
Digitizing and Delivering Audio and Video
Digitizing and Delivering Audio and VideoDigitizing and Delivering Audio and Video
Digitizing and Delivering Audio and Video
 
Janus Workshop pt.2 @ ClueCon 2021
Janus Workshop pt.2 @ ClueCon 2021Janus Workshop pt.2 @ ClueCon 2021
Janus Workshop pt.2 @ ClueCon 2021
 
WordCamp Lightning Talk: Podcasting and Live Streaming with WordPress
WordCamp Lightning Talk: Podcasting and Live Streaming with WordPressWordCamp Lightning Talk: Podcasting and Live Streaming with WordPress
WordCamp Lightning Talk: Podcasting and Live Streaming with WordPress
 
Web & Apps Design for Mobile Devices
Web & Apps Design for Mobile DevicesWeb & Apps Design for Mobile Devices
Web & Apps Design for Mobile Devices
 
Become a rockstar using FOSS!
Become a rockstar using FOSS!Become a rockstar using FOSS!
Become a rockstar using FOSS!
 
COMP 4010 Lecture5 VR Audio and Tracking
COMP 4010 Lecture5 VR Audio and TrackingCOMP 4010 Lecture5 VR Audio and Tracking
COMP 4010 Lecture5 VR Audio and Tracking
 
WebRTC Rockstars Asian Tour 2017
WebRTC Rockstars Asian Tour 2017WebRTC Rockstars Asian Tour 2017
WebRTC Rockstars Asian Tour 2017
 

More from Lorenzo Miniero

More from Lorenzo Miniero (8)

Getting AV1/SVC to work in the Janus WebRTC Server
Getting AV1/SVC to work in the Janus WebRTC ServerGetting AV1/SVC to work in the Janus WebRTC Server
Getting AV1/SVC to work in the Janus WebRTC Server
 
BWE in Janus
BWE in JanusBWE in Janus
BWE in Janus
 
Real-Time Text and WebRTC @ Kamailio World 2023
Real-Time Text and WebRTC @ Kamailio World 2023Real-Time Text and WebRTC @ Kamailio World 2023
Real-Time Text and WebRTC @ Kamailio World 2023
 
Janus + NDI @ ClueCon 2021
Janus + NDI @ ClueCon 2021Janus + NDI @ ClueCon 2021
Janus + NDI @ ClueCon 2021
 
Insertable Streams and E2EE @ ClueCon2020
Insertable Streams and E2EE @ ClueCon2020Insertable Streams and E2EE @ ClueCon2020
Insertable Streams and E2EE @ ClueCon2020
 
Turning live events to virtual with Janus
Turning live events to virtual with JanusTurning live events to virtual with Janus
Turning live events to virtual with Janus
 
Simulcast/SVC @ IIT-RTC 2019
Simulcast/SVC @ IIT-RTC 2019Simulcast/SVC @ IIT-RTC 2019
Simulcast/SVC @ IIT-RTC 2019
 
Fuzzing Janus @ IPTComm 2019
Fuzzing Janus @ IPTComm 2019Fuzzing Janus @ IPTComm 2019
Fuzzing Janus @ IPTComm 2019
 

Recently uploaded

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 

Recently uploaded (20)

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 

WebRTC, RED and Janus @ ClueCon21

  • 1. Audio redundancy in WebRTC and Janus via RED Lorenzo Miniero ClueCon – Chicago, IL, USA (kinda!) October 27th 2021
  • 2. Who am I? Lorenzo Miniero • Ph.D @ UniNA • Chairman @ Meetecho • Main author of Janus® Contacts and info • lorenzo@meetecho.com • https://twitter.com/elminiero • https://www.slideshare.net/LorenzoMiniero • https://soundcloud.com/lminiero • https://lminiero.bandcamp.com
  • 3. Just a few words on Meetecho • Co-founded in 2009 as an academic spin-off • University research efforts brought to the market • Completely independent from the University • Focus on real-time multimedia applications • Strong perspective on standardization and open source • Several activities • Consulting services • Commercial support and Janus licenses • Streaming of live events (IETF, ACM, etc.) • Proudly brewed in sunny Napoli, Italy
  • 5. Remember Janus? Janus General purpose, open source WebRTC server • https://github.com/meetecho/janus-gateway • Demos and documentation: https://janus.conf.meetecho.com • Community: https://groups.google.com/forum/#!forum/meetecho-janus
  • 8. A ton of scenarios done today with Janus! • SIP and RTSP gatewaying • WebRTC-based call/contact centers • Conferencing & collaboration • E-learning & webinars • Cloud platforms • Media production • Broadcasting & Gaming • Identity verification • Internet of Things • Augmented/Virtual Reality • ...and more!
  • 9. It’s not just about video! • Video obviously takes the lion’s share, most of the times • Pretty much ubiquitous • Most use cases assume video, one way or another • It’s not the only thing that matters, though • We still need to communicate, somehow • Audio (and data) can be just as important, if not more • Some applications even focus JUST on audio! • ... and not only call/contact centers, PBX, or legacy infrastructures
  • 10. It’s not just about video! • Video obviously takes the lion’s share, most of the times • Pretty much ubiquitous • Most use cases assume video, one way or another • It’s not the only thing that matters, though • We still need to communicate, somehow • Audio (and data) can be just as important, if not more • Some applications even focus JUST on audio! • ... and not only call/contact centers, PBX, or legacy infrastructures
  • 11. It’s not just about video! • Video obviously takes the lion’s share, most of the times • Pretty much ubiquitous • Most use cases assume video, one way or another • It’s not the only thing that matters, though • We still need to communicate, somehow • Audio (and data) can be just as important, if not more • Some applications even focus JUST on audio! • ... and not only call/contact centers, PBX, or legacy infrastructures
  • 12. A relevant example: Clubhouse
  • 13. Another relevant example: Twitter Spaces
  • 14. You didn’t hear it from me...
  • 15. “Can WebRTC help musicians?” https://fosdem.org/2021/schedule/event/webrtc_musicians/
  • 16. WebRTC and audio • A couple of mandatory-to-implement codecs • Opus + G.711 • G.711 just there as a fallback (and legacy interopability) • Opus FTW! • High quality audio codec designed for the Internet • Very flexible in sampling rates, bitrates, etc. • Support for stereo, and different “profiles” for voice/music • Surround availble too, on an experimental basis (multiopus) • A few interesting “tools” • Audio levels RTP extension (VAD) • Opus inband Forward Error Correction (FEC) • Opus Discontinuous transmission (DTX)
  • 17. WebRTC and audio • A couple of mandatory-to-implement codecs • Opus + G.711 • G.711 just there as a fallback (and legacy interopability) • Opus FTW! • High quality audio codec designed for the Internet • Very flexible in sampling rates, bitrates, etc. • Support for stereo, and different “profiles” for voice/music • Surround availble too, on an experimental basis (multiopus) • A few interesting “tools” • Audio levels RTP extension (VAD) • Opus inband Forward Error Correction (FEC) • Opus Discontinuous transmission (DTX)
  • 18. WebRTC and audio • A couple of mandatory-to-implement codecs • Opus + G.711 • G.711 just there as a fallback (and legacy interopability) • Opus FTW! • High quality audio codec designed for the Internet • Very flexible in sampling rates, bitrates, etc. • Support for stereo, and different “profiles” for voice/music • Surround availble too, on an experimental basis (multiopus) • A few interesting “tools” • Audio levels RTP extension (VAD) • Opus inband Forward Error Correction (FEC) • Opus Discontinuous transmission (DTX)
  • 19. Audio-only: SFU or MCU? • SFUs ideal to just relay media • No mixing/transcoding to worry about −→ less CPU on server, less delay • More streams to distribute −→ more bandwidth needed • Different streams −→ more control on UI • MCUs ideal to just mix media • Mixing/transcoding taking place −→ more CPU on server, more delay • Just one stream to distribute −→ bandwidth constant • Single output stream −→ UI rendering constrained • Sometimes it makes sense to use them both! • Use SFU where applicable (e.g., video, plenty of bandwidth) • Use MCU to complement (e.g., audio, lower power devices) • Besides, an MCU can mix SFU streams to broadcast to a CDN!
  • 20. Audio-only: SFU or MCU? • SFUs ideal to just relay media • No mixing/transcoding to worry about −→ less CPU on server, less delay • More streams to distribute −→ more bandwidth needed • Different streams −→ more control on UI • MCUs ideal to just mix media • Mixing/transcoding taking place −→ more CPU on server, more delay • Just one stream to distribute −→ bandwidth constant • Single output stream −→ UI rendering constrained • Sometimes it makes sense to use them both! • Use SFU where applicable (e.g., video, plenty of bandwidth) • Use MCU to complement (e.g., audio, lower power devices) • Besides, an MCU can mix SFU streams to broadcast to a CDN!
  • 21. Audio-only: SFU or MCU? • SFUs ideal to just relay media • No mixing/transcoding to worry about −→ less CPU on server, less delay • More streams to distribute −→ more bandwidth needed • Different streams −→ more control on UI • MCUs ideal to just mix media • Mixing/transcoding taking place −→ more CPU on server, more delay • Just one stream to distribute −→ bandwidth constant • Single output stream −→ UI rendering constrained • Sometimes it makes sense to use them both! • Use SFU where applicable (e.g., video, plenty of bandwidth) • Use MCU to complement (e.g., audio, lower power devices) • Besides, an MCU can mix SFU streams to broadcast to a CDN!
  • 22. We do use both in our Virtual Event Platform! https://commcon.xyz/session/turning-live-events-to-virtual-with-janus
  • 23. Many efforts focused on audio in Janus, recently • Modular nature of Janus encourages new functionality • Not necessarily in new plugins • VideoRoom, AudioBridge, Streaming plugins can all benefit • Several activities done, started or planned to enhance audio experience • Mostly in AudioBridge... (due to the nature of the plugin) • ... but some features actually available to all plugins! • Many coming from requirements for our Virtual Event Platform • But we like to experiment as well! • Main topic of a recent talk @ Open Source World • https://www.slideshare.net/LorenzoMiniero/janus-audio-open-source-world
  • 24. Many efforts focused on audio in Janus, recently • Modular nature of Janus encourages new functionality • Not necessarily in new plugins • VideoRoom, AudioBridge, Streaming plugins can all benefit • Several activities done, started or planned to enhance audio experience • Mostly in AudioBridge... (due to the nature of the plugin) • ... but some features actually available to all plugins! • Many coming from requirements for our Virtual Event Platform • But we like to experiment as well! • Main topic of a recent talk @ Open Source World • https://www.slideshare.net/LorenzoMiniero/janus-audio-open-source-world
  • 25. Many efforts focused on audio in Janus, recently • Modular nature of Janus encourages new functionality • Not necessarily in new plugins • VideoRoom, AudioBridge, Streaming plugins can all benefit • Several activities done, started or planned to enhance audio experience • Mostly in AudioBridge... (due to the nature of the plugin) • ... but some features actually available to all plugins! • Many coming from requirements for our Virtual Event Platform • But we like to experiment as well! • Main topic of a recent talk @ Open Source World • https://www.slideshare.net/LorenzoMiniero/janus-audio-open-source-world
  • 26. Many efforts focused on audio in Janus, recently • Modular nature of Janus encourages new functionality • Not necessarily in new plugins • VideoRoom, AudioBridge, Streaming plugins can all benefit • Several activities done, started or planned to enhance audio experience • Mostly in AudioBridge... (due to the nature of the plugin) • ... but some features actually available to all plugins! • Many coming from requirements for our Virtual Event Platform • But we like to experiment as well! • Main topic of a recent talk @ Open Source World • https://www.slideshare.net/LorenzoMiniero/janus-audio-open-source-world
  • 27. Audio redundancy via RED • Old RTP payload format for Redundant Audio Data (RED) • https://datatracker.ietf.org/doc/html/rfc2198 • Recently added to Chrome on an experimental basis • https://bugs.chromium.org/p/webrtc/issues/detail?id=11640 • https://webrtchacks.com/red-improving-audio-quality-with-redundancy/ • https://webrtchacks.com/implementing-redundant-audio-on-an-sfu/ • Basically a simple way to group multiple audio frames in a single RTP packet • Current audio frame + one or more previously sent frames • Allows recipient to easily recover lost packets at the cost of more bandwidth
  • 28. Audio redundancy via RED • Old RTP payload format for Redundant Audio Data (RED) • https://datatracker.ietf.org/doc/html/rfc2198 • Recently added to Chrome on an experimental basis • https://bugs.chromium.org/p/webrtc/issues/detail?id=11640 • https://webrtchacks.com/red-improving-audio-quality-with-redundancy/ • https://webrtchacks.com/implementing-redundant-audio-on-an-sfu/ • Basically a simple way to group multiple audio frames in a single RTP packet • Current audio frame + one or more previously sent frames • Allows recipient to easily recover lost packets at the cost of more bandwidth
  • 29. Audio redundancy via RED • Old RTP payload format for Redundant Audio Data (RED) • https://datatracker.ietf.org/doc/html/rfc2198 • Recently added to Chrome on an experimental basis • https://bugs.chromium.org/p/webrtc/issues/detail?id=11640 • https://webrtchacks.com/red-improving-audio-quality-with-redundancy/ • https://webrtchacks.com/implementing-redundant-audio-on-an-sfu/ • Basically a simple way to group multiple audio frames in a single RTP packet • Current audio frame + one or more previously sent frames • Allows recipient to easily recover lost packets at the cost of more bandwidth
  • 35. Negotiating RED in SDP Offer (“I support RED”) m=audio 9 UDP/TLS/RTP/SAVPF 111 63 103 104 9 0 8 106 105 13 110 112 113 126 [..] a=rtpmap:111 opus/48000/2 a=rtpmap:63 red/48000/2 a=fmtp:63 111/111 [..] Answer (”Ok, let’s use RED”) m=audio 9 UDP/TLS/RTP/SAVPF 63 111 [..] a=rtpmap:63 red/48000/2 a=rtpmap:111 opus/48000/2 a=fmtp:63 111/111 [..]
  • 36. Support for audio redundancy via RED in Janus • Support in Janus needed work in both core and plugins • Core needed to negotiate RED, and be able to unpack/pack RED • Plugins needed to be able to do something with the data • Important to support both endpoints that can do RED, and those who can’t • RED-to-RED and nonRED-to-nonRED are easy • In other cases, Janus may have to pack/unpack RED accordingly • First integration basically done in most plugins • Still missing in AudioBridge, though If you want to learn more... (PR in testing phase) https://www.meetecho.com/blog/opus-red/
  • 37. Support for audio redundancy via RED in Janus • Support in Janus needed work in both core and plugins • Core needed to negotiate RED, and be able to unpack/pack RED • Plugins needed to be able to do something with the data • Important to support both endpoints that can do RED, and those who can’t • RED-to-RED and nonRED-to-nonRED are easy • In other cases, Janus may have to pack/unpack RED accordingly • First integration basically done in most plugins • Still missing in AudioBridge, though If you want to learn more... (PR in testing phase) https://www.meetecho.com/blog/opus-red/
  • 38. Support for audio redundancy via RED in Janus • Support in Janus needed work in both core and plugins • Core needed to negotiate RED, and be able to unpack/pack RED • Plugins needed to be able to do something with the data • Important to support both endpoints that can do RED, and those who can’t • RED-to-RED and nonRED-to-nonRED are easy • In other cases, Janus may have to pack/unpack RED accordingly • First integration basically done in most plugins • Still missing in AudioBridge, though If you want to learn more... (PR in testing phase) https://www.meetecho.com/blog/opus-red/
  • 39. Support for audio redundancy via RED in Janus • Support in Janus needed work in both core and plugins • Core needed to negotiate RED, and be able to unpack/pack RED • Plugins needed to be able to do something with the data • Important to support both endpoints that can do RED, and those who can’t • RED-to-RED and nonRED-to-nonRED are easy • In other cases, Janus may have to pack/unpack RED accordingly • First integration basically done in most plugins • Still missing in AudioBridge, though If you want to learn more... (PR in testing phase) https://www.meetecho.com/blog/opus-red/
  • 45. A few challenges to address • RED to non-RED doesn’t currently take into account redundant info • If RED packet N-1 is lost, we don’t use packet N to get lost one • RED packetization code in Janus assumes in-order packets • May not always be the case (e.g., Streaming plugin and external RTP source) • RED packetization is shared when doing one-to-many • New subscribers get redundant info on pre-join audio packets • Switching subscription in-session briefly mixes redundant info of different sessions • (N-1 of new stream) != (N-1 of previous stream) • Discontinuous Transmission (DTX) can cause issues • Big timestamp jumps can overflow the smaller “timestamp” diff in RED
  • 46. A few challenges to address • RED to non-RED doesn’t currently take into account redundant info • If RED packet N-1 is lost, we don’t use packet N to get lost one • RED packetization code in Janus assumes in-order packets • May not always be the case (e.g., Streaming plugin and external RTP source) • RED packetization is shared when doing one-to-many • New subscribers get redundant info on pre-join audio packets • Switching subscription in-session briefly mixes redundant info of different sessions • (N-1 of new stream) != (N-1 of previous stream) • Discontinuous Transmission (DTX) can cause issues • Big timestamp jumps can overflow the smaller “timestamp” diff in RED
  • 47. A few challenges to address • RED to non-RED doesn’t currently take into account redundant info • If RED packet N-1 is lost, we don’t use packet N to get lost one • RED packetization code in Janus assumes in-order packets • May not always be the case (e.g., Streaming plugin and external RTP source) • RED packetization is shared when doing one-to-many • New subscribers get redundant info on pre-join audio packets • Switching subscription in-session briefly mixes redundant info of different sessions • (N-1 of new stream) != (N-1 of previous stream) • Discontinuous Transmission (DTX) can cause issues • Big timestamp jumps can overflow the smaller “timestamp” diff in RED
  • 48. A few challenges to address • RED to non-RED doesn’t currently take into account redundant info • If RED packet N-1 is lost, we don’t use packet N to get lost one • RED packetization code in Janus assumes in-order packets • May not always be the case (e.g., Streaming plugin and external RTP source) • RED packetization is shared when doing one-to-many • New subscribers get redundant info on pre-join audio packets • Switching subscription in-session briefly mixes redundant info of different sessions • (N-1 of new stream) != (N-1 of previous stream) • Discontinuous Transmission (DTX) can cause issues • Big timestamp jumps can overflow the smaller “timestamp” diff in RED
  • 49. A few challenges to address • RED to non-RED doesn’t currently take into account redundant info • If RED packet N-1 is lost, we don’t use packet N to get lost one • RED packetization code in Janus assumes in-order packets • May not always be the case (e.g., Streaming plugin and external RTP source) • RED packetization is shared when doing one-to-many • New subscribers get redundant info on pre-join audio packets • Switching subscription in-session briefly mixes redundant info of different sessions • (N-1 of new stream) != (N-1 of previous stream) • Discontinuous Transmission (DTX) can cause issues • Big timestamp jumps can overflow the smaller “timestamp” diff in RED
  • 50. What about the impact on bandwidth? • RED does help with redundancy... • ... but uses much more bandwidth than usual for audio! • Initial integration in Chrome used distance of two “generations” • Each audio packet contains payload of previous two packets • Bitrate of audio stream increases considerably! • Less bandwidth available for other streams, e.g., video • Latest version defaults to a single redundant packet instead • Overridable with WebRTC-Audio-Red-For-Opus/Enabled-[1-9]/
  • 51. What about the impact on bandwidth? • RED does help with redundancy... • ... but uses much more bandwidth than usual for audio! • Initial integration in Chrome used distance of two “generations” • Each audio packet contains payload of previous two packets • Bitrate of audio stream increases considerably! • Less bandwidth available for other streams, e.g., video • Latest version defaults to a single redundant packet instead • Overridable with WebRTC-Audio-Red-For-Opus/Enabled-[1-9]/
  • 52. What about the impact on bandwidth? • RED does help with redundancy... • ... but uses much more bandwidth than usual for audio! • Initial integration in Chrome used distance of two “generations” • Each audio packet contains payload of previous two packets • Bitrate of audio stream increases considerably! • Less bandwidth available for other streams, e.g., video • Latest version defaults to a single redundant packet instead • Overridable with WebRTC-Audio-Red-For-Opus/Enabled-[1-9]/
  • 53. What about the impact on bandwidth? • RED does help with redundancy... • ... but uses much more bandwidth than usual for audio! • Initial integration in Chrome used distance of two “generations” • Each audio packet contains payload of previous two packets • Bitrate of audio stream increases considerably! • Less bandwidth available for other streams, e.g., video • Latest version defaults to a single redundant packet instead • Overridable with WebRTC-Audio-Red-For-Opus/Enabled-[1-9]/
  • 54. Thanks! Questions? Comments? Get in touch! • https://twitter.com/elminiero • https://twitter.com/meetecho • https://www.meetecho.com