ONE STAGE OF A CHAIN — WHAT ARRIVES, WHAT LEAVES, WHAT BREAKS DOWNSTREAM
Where This Sits In The Encoding Pipeline
A video encoder is not one algorithm but eight stages in a fixed order, and the order is not arbitrary: each stage exists because the one before it made its job possible. This tool models one of them. The chain below links to the other seven.
Bitrate vs Size Calculator — converts the bitrate the chain produced into a file size, and into a delivery constraint
- What arrives
- An average bitrate from the encoded stream.
- What leaves
- A file size, and an answer to whether it fits.
- What the next stage assumes
- Nothing downstream. This is where the constraint originally came from, though — the target that gets handed to rate control at stage 07.
- What goes wrong here
- Size is bitrate multiplied by duration, so it is arithmetic rather than a codec decision. The useful direction is backwards: a size limit divided by duration is the bitrate budget every earlier stage has to live inside.
Problem solved in full
-
File size of a ten-minute video at 6 Mbit/s of picture 5 steps
A ten-minute video at 6 Mbit/s of picture and 192 kbit/s of sound. Work out the file size, and then answer the question that decides encoder settings: how much of it is the audio?
-
Bitrates add. The container carries both streams, so the number that matters for size is their sum.
-
Size is bitrate times duration, and the only trap is the units: bitrates are in bits, files are measured in bytes. Divide by eight, and the factor everyone forgets is exactly the factor that makes an estimate come out eight times too large.
-
Then the container itself costs something — headers, index, interleaving — modelled here as 3%.
-
The audio share is the interesting ratio. It is 3.1% of the bitrate, and that same 3.1% is 14.4 MB of the finished file.
-
Against a 520 MB cap the file has 41.67 MB to spare, so the video bitrate could rise a little rather than the audio being cut.
Answer
The tool prints a total of 6.192 Mbit/s, a payload of 464.4 MB and a final size of 478.33 MB. The number that changes decisions is 3.1%. Halving the audio bitrate — the first thing people reach for — saves about 7 MB of a 478 MB file, while costing every listener audible quality. Taking the same 7 MB off the video is a 1.5% bitrate cut nobody would see. The arithmetic is trivial and the conclusion is routinely got backwards, because 192 kbit/s sounds like a lot next to 6 Mbit/s only until you notice which one is the small number.
-
References (1)
- The binary prefixes block 3 separates from the SI ones: IEC 80000-13:2008, Quantities and units — Part 13: Information science and technology, which defines the kibibyte, mebibyte and gibibyte precisely so that "MB" need not be ambiguous.