About Constant Bitrate Encoding

What most of us are used to when we encode an MP3 File, is that we can set a bitrate – such as 192kbps – and, the codec will produce an MP3 File with that bitrate. If that was all there is to it, we’d have Constant Bitrate encoding, aka ‘CBR’.

But in many cases, the actual encoding scheme is Variable Bitrate (‘VBR’), which has been modified to be Adaptive Variable Bitrate (‘AVBR’).

The way AVBR works, is that it nests the actual encoding algorithm inside a loop, with the premise that the user has nevertheless set a target bitrate. The loop then feeds the actual algorithm several quality-factors, to encode the same granule of sound, in multiple attempts, to find the maximum quality-factor, which does not cause the encoding to exceed the number of bits, which have been allocated for the algorithm to take up, in its encoding of 1 granule of sound.

This quality-factor is then also used, to produce output. And, in case the actual number of bits output are less than the allocated number of bits, the difference is next added to the number of bits that act as a target, with which the next granule of sound is to be encoded.

Encoding schemes that are truly CBR, are often ones which are not compressed, plus also perhaps ‘DPCM‘… Most of the other schemes, such as ‘MP3′ and ‘OGG’, are really AVBR or VBR.

(Updated 03/11/2018 : )

Continue reading About Constant Bitrate Encoding

3GP Video File Support

I have an Android phone app, which records videos to .3GP File format. The most important fact to remember about video file formats, is that the file-name extension identifies a container file, for which there may or may not be more than one video and audio CODEC supported.

Some users have reported problems, in getting 3GP Video Files to play, or to import, on Linux computers. This is probably the case, because this container format may in some cases store H.263 video and AMR audio. The problem here is in the fact that AMR audio is a proprietary CODEC, which cannot really be shipped for free for licensing reasons.

In my case I am in luck, because my app stores video compressed with the H.264 Video CODEC, and with the AAC Audio CODEC. That means that my video files will play and be imported into projects without effort.

I am sorry if this provides no relief to other users.