Video: I know X, what does WebRTC get me?

WebRTC is now a W3C standard providing sub-second peer-to-peer video and audio streaming with NAT traversal. Widely used for video conferencing, its sub-second latency has also been the focus of video streaming companies such as Millicast and Limelight (to name but two) who aim to deliver this otherwise peer-to-peer technology to thousands or millions of people in under a second enabling interactive video, gamefied streams, auctions and ultra-low-latency sports.

Addressing directly people using other streaming protocols, Pion creator Sean DuBois spoke at SF Video Tech about what WebRTC brings over and above protocols like RTMP, SRT and RIST. At the heart of it, WebRTC, like SRT and RIST, creates a connection over which it can send a variety of data. Whilst we expect media to be sent, actually, file transfer can be easily achieved – let’s not forget the whole of SRT is build upon UDT which is specifically a file delivery utility. Where file transfer can be achieved, so can real-time data & metadata transfer.

Sean quickly summarises WebRTC as a Protocol between (typically) browsers, an peer-to-peer secure connection over which multiple audio & video streams can flow. In common with RIST and other recent protocols, it’s based on many pre-existing
technologies such as SRTP, DTLS, ICE and SDP to deliver signalling, connection management, encryption and communication.

 

 

The list of improvements over RTMP is very long. They’re spelt out concisely in the video so we will highlight just a few here. Importantly, low-latency is key. RTMP was low-latency for its time, but not by today’s standards. Google’s Stadia can boast 125ms video latency for a keypress, explains Sean. DTLS and SRTP are essential for security but are well understood, trusted methods of securing your data. DTLS is pretty much exactly the same as the TLS which secures your bank transfers, just moved into UDP instead of TCP. However, WebRTC can work by exchanging ‘fingerprints’ (DTLS-SRTP) instead of the full trusted certificate infrastructure that underpins TLS on the web. Removing the requirement for certs is a big boost for flexibility and agility as long as you are confident you can exchange fingerprints securely ahead of time.

NAT traversal is also a big boon where, even with both endpoints behind a firewall, endpoints can always find a way to communicate although this does mean that ICE servers are needed to facilitate connectivity. Within broadcasting, however, it’s more likely that you’ll have control of one end so this is less needed. Sean highlights the ability to send multiple quality levels within the same stream using the ‘simulcast’ ability of WebRTC.

Sean then looks at SRT and RIST. Both of these are low-latency streaming protocols which can, both, also provide sub-second streaming for good connections with a relatively low RTT. Sean highlights the lack of SRT and RIST to negotiate the codec in use and their optional security. Being focused more on delivering contribution feeds, they tend to have a more static configuration often created after a programme of testing to ensure the quality will be acceptable to the broadcaster/streaming provider.

To finish, Sean highlights a whole series of interesting, innovative uses of WebRTC from informal group streaming to drones to shared online games to file transfers and more.

Watch now!
Speaker

Sean DuBois Sean DuBois
Developer, Apple
Creator of Pion WebRTC

Video: The QUIC-ematic universe season 2020-2021 preview

QUIC is an encrypted transport protocol with better performance than HTTP and HTTP/2. While young, it’s already seeing some use in the larger internet companies who are learning how best to harness the optimisations. One of the stark differences is that it’s built on top of UDP rather than TCP. This is one of the main ways it increases efficiency. Freed from TCP’s constant acknowledgement of packets, QUIC also ensures reliable delivery but on its own terms which allows it to prioritise speedy delivery over acknowledgement admin. We’ve covered QUIC before, so if it’s new to you, check out this explainer as this talk is an update on what’s happened in 2020 and the plans for 2021 as QUIC aims to be standardised and much more available.

Lucas Pardue from Cloudflare works on the IETF working group devoted to QUIC and spoke at Demuxed 2020. “The IETF are standardisers” he says with QUIC being on its 31st draft with a move to standardise during 2021 what is called ‘IETF QUIC’ to differentiate from a slightly different version of QUIC from Google. IETF quick, Lucas outlines, delivers secure, reliable stream multiplexing.
 

 

QUIC actually forms a base layer for other applications like HTTP/3 with HTTP semantics to work on top of. Like most modern standards, QUIC is actually a name for more than one document. There is a transport layer, header compression, TLS handshake description and a document for recovery and loss protection. QUIC itself lives on UDP datagrams which is why one of the new options coming is to turn off some of the reliability which has been built on top of UDP to deliver TCP-like reliability for data which doesn’t really need it. One possibility here is running a QUIC tunnel where one QUIC connection actually has many QUIC streams within it. In this circumstance, you only want any one bit of data being protected by one reliable transmission mechanism. So you’d want to be turning off reliable transmission for your internal QUIC streams as they would be protected by the outer QUIC layer. There is a project called MASQUE which is working on this.

As with anything arriving on the market, it’s important to establish interoperability. We see this with the JT-NM and SRT plugfests. Lucas shows us the QUIC interop tester which automatically tests the latest implementations with each other and shows the results in a matrix plus allows access to logs and packet traces.

Lucas reminds us the QUIC streams are a first-class transport primitive providing reliable delivery. Within a stream, data will be delivered in order, but QUIC doesn’t specify how to schedule multiplexed streams. HTTP3 initially borrowed HTTP/2’s prioritisation scheme but found a better way to prioritise which is currently being discussed and finalised. Lucas has been working on quiche, Cloudflare’s own implementation of QUIC and shows a three-step process to getting quiche up and running.

Web Transport is another offering from QUIC which complements WebSocket which gives web apps better access to QUIC itself. The Chome Origin Trial explains how this is built in Chrome. Lucas talks about a test project he built on top of existing examples which is hosted at http3.wtf

Lucas ends by summarising the coming year: The working group is aiming to deliver documents to an IETF last call ahead of publication. The community will continue to get deployment experience as new users ar already working on enabling the technology and there is still work to be done on other adopted work items as well as considering others. Lucas ends by encouraging viewers to join in with the community,

Watch now!
Speaker

Lucas Pardue Lucas Pardue
Senior Software Engineer, Cloudflare
Co-Chair of the QUIC working group, IETF

Video: AES67/ST 2110-30 over WAN

Dealing with professional audio, it’s difficult to escape AES67 particularly as it’s embedded within the SMPTE ST 2110-30 standard. Now, with remote workflows prevalent, moving AES67 over the internet/WAN is needed more and more. This talk brings the good news that it’s certainly possible, but not without some challenges.

Speaking at the SMPTE technical conference, Nicolas Sturmel from Merging Technologies outlines the work being done within the AES SC-02-12M working group to define the best ways of working to enable easy use of AES67 on the WAn. He starts by outlining the fact that AES67 was written to expect short links on a private network that you can completely control which causes problems when using the WAN/internet with long-distance links on which your bandwidth or choice of protocols can be limited.

To start with, Nicolas urges anyone to check they actually need AES67 over the WAN to start with. Only if you need precise timing (for lip-sync for example) with PCM quality and low latencies from 250ms down to as a little as 5 milliseconds do you really need AES67 instead of using other protocols such as ACIP, he explains. The problem being that any ping on the internet, even to something fairly close, can easily take 16 to 40ms for the round trip. This means you’re guaranteed 8ms of delay, but any one packet could be as late as 20ms known as the Packet Delay Variation (PDV).

Link

Not only do we need to find a way to transmit AES67, but also PTP. The Precise Time Protocol has ways of coping for jitter and delay, but these don’t work well on WAN links whether the delay in one direction may be different to the delay for a packet in the other direction. PTP also isn’t built to deal with the higher delay and jitter involved. PTP over WAN can be done and is a way to deliver a service but using a GPS receiver at each location is a much better solution only hampered by cost and one’s ability to see enough of the sky.

The internet can lose packets. Given a few hours, the internet will nearly always lose packets. To get around this problem, Nicolas looks at using FEC whereby you are constantly sending redundant data. FEC can send up to around 25% extra data so that if any is lost, the extra information sent can be leveraged to determine the lost values and reconstruct the stream. Whilst this is a solid approach, computing the FEC adds delay and the extra data being constantly sent adds a fixed uplift on your bandwidth need. For circuits that have very few issues, this can seem wasteful but having a fixed percentage can also be advantageous for circuits where a predictable bitrate is much more important. Nicolas also highlights that RIST, SRT or ST 2022-7 are other methods that can also work well. He talks about these longer in his talk with Andreas Hildrebrand

Watch now!
Speaker

Nicolas Sturmel Nicolas Sturmel
Product Manager, Senior Technologist,
Merging Technologies

From WebRTC to RTMP

Continuing our look at the most popular videos of 2020, in common with the previous post on SRT, today we look at replacing RTMP for ingest. This time, WebRTC is demonstrated as an option. With sub-second latency, WebRTC is a compelling replacement for RTMP.
 

 
Read what we said about it the first time in the original article, but you’ll see that Nick Chadwick from Mux takes us through the how RTMP works and where the gaps are as it’s phased out. He steps through the alternatives showing how even the low-latency delivery formats don’t fit the bill for contribution and shows how WebRTC can be a sub-second solution.

RIST and SRT saw significant and continued growth in use throughout 2020 as delivery formats and appear to be more commonly used than WebRTC, though that’s not to say that WebRTC isn’t continuing to grow within the broadcast community. SRT and RIST are both designed for contribution in that they actively manage packet loss, allow any codecs to be used and provide for other data to be sent, too. Overall, this tends to give them the edge, particularly for hardware products. But WebRTC’s wide availability on computers can be a bonus in some circumstances. Have a listen and come to your own conclusion.

Watch now!
Speaker

Nick Chadwick Nick Chadwick
Software Engineer,
Mux