Apple’s Bitrate Control Strategy: Do as I Do, Not as I Say

Apple’s HLS Authoring Specifications for Apple Devices approves up to 200% constrained VBR but Apple’s actual encodes are more like 110-120% constrained.

What Apple Says

As you probably know, Apple recently made sweeping changes to their HLS recommendations, including changing from 110% constrained VBR for VOD in TN2224, to 200% constrained VBR in the HLS Authoring Specifications for Apple Devices (1.23. For VOD content the peak bit rate SHOULD be no more than 200% of the average bit rate). This was concerning to me because as I explained in my article Bitrate Control and QoE-CBR is Better, under certain conditions, 200% constrained VBR could seriously degrade the quality of experience (QoE) to viewers.

Table 1: CBR delivered vastly superior QoE to VBR.

The data is shown in Table 1. Both files were encoded using the same bitrate ladder, which peaked at 4.5 Mbps for the 1080p file. The file on the left was encoded using 200% constrained VBR, with CBR encoding on the right. During playback, bandwidth was restricted to 3.2 Mbps using Charles Proxy.

With the VBR file, the user cycled through many data rate adjustments, viewing fragments as low a 1 Mbps, while with the CBR file, 94% of the fragments was from the same 2.1 Mbps stream. In addition, there were three stoppages with the VBR file and a temporary loss of A/V sync. None of this occurred with the CBR file, which played smoothly throughout.

What about video quality? With this particular test file, the 1080p VBR version had a slightly higher PSNR value than the CBR file (41.1 dB compared to 40.7 dB) a qualitative difference that would not be visible to the normal viewer.

What Apple Does

So, Apple now says the peak bitrate should not be higher than 200%. What are they actually doing?

For a webinar I produced last week, Defining Your Encoding Ladder (free replay available here through 9/15/2017, registration required), I downloaded the master.m3u8 file for Apple’s mixed H.264 and HEVC encoding ladder. As you may know, the master.m3u8 contains certain encoding details for all files in the encoding ladder, and Table 2 shows those used by Apple for the HEVC files.

Table 2: Apple’s HEVC encoding ladder showing about 112% constrained VBR.

As you can see, Apple listed both peak bandwidth and average bandwidth in the file, which makes the constrained VBR percentage easy to compute. There it is on the extreme right, averaging 112%. Though not shown, the H.264 ladder averaged 118%.

Looking back at Apple’s statement in the HLS encoding specifications–”For VOD content the peak bit rate SHOULD be no more than 200% of the average bit rate”– it’s clear that Apple isn’t requiring 200% constrained VBR, or even recommending it. So don’t take it as a license to use 200% constrained VBR to chase that last bit of quality at the potential cost of overall quality of experience. So yeah, the headline is a bit unfair, but if it convinced you to read this far, hopefully, you’ve found the experience worthwhile.

What did I recommend in Bitrate Control and QoE-CBR is Better? Using 110% constrained VBR to avoid transient quality issues sometimes experienced by CBR encoding, and the QoE risks of 200% constrained VBR. I seriously doubt that Apple’s encoding procedures were impacted by this, but it’s nice to see that Apple seems to agree with this recommendation.

Author’s note: the PDF download available with the free webinar contains both Apple ladders, plus ladders from Bitmovin (HLS, HEVC only) and MainConcept (HLS, mixed H.264 and HEVC).

About the author: As a consultant, Jan Ozer helps OTT and other large scale video streamers optimize video quality and QoE, and the efficiency of their encoding workflows. Ozer is the author of Video Encoding by the Numbers: Eliminate the Guesswork from Your Streaming Video, and contributing editor for Streaming Media Magazine. He blogs at the Streaming Learning Center.

About Jan Ozer

I help companies train new technical hires in streaming media-related positions; I also help companies optimize their codec selections and encoding stacks, and evaluate new encoders and codecs.

Check Also

Encoding H.264 with Wirecast

Beginner’s Guide to Encoding H.264

The H.264 codec is still the most widely used video compression technology — aka codec …

Leave a Reply

Your email address will not be published. Required fields are marked *