Log in

View Full Version : Bitrate trouble


Sparkov
15th January 2009, 23:27
I'm having trouble calculating bitrates for raw AVC files to achieve exact file sizes. As a test, I tried to encode a 60 sec clip with a 2-pass encode, aiming for a 50 MB file. I calculated the bitrate as follows:

50 MB = 51,200 KB = 409,600 Kb

Bitrate = Size / Time
= 409,600 / 60
=6,826.67

I used 6,826 kbps but only ended up with a 48.9 MB file. Any ideas? MediaInfo tells me the resulting video bitrate is exactly 6826 kbps so why is the file smaller than expected?

J_Darnley
15th January 2009, 23:57
50 MiB is 419430400 bits or 419430.4 kbits therefore use 6990.5 kbits per second

Snowknight26
16th January 2009, 00:21
You're probably miscalculating because Windows, which I'm assuming you're using, uses MiB while showing "MB".

Esurnir
16th January 2009, 00:52
windows : 1MiB = 1024 KiB = 1048576B = 8388608 b
x264 : 1kbps = 1000bps

kemuri-_9
16th January 2009, 03:17
data storage uses 2^10 (1024) when going up an SI prefix.*
data transfer uses 10^3 (1000) when going up an SI prefix.

*= vendors sell data storage using the 10^3 method.

i.e.
10 MB is 10 * 1024 * 1024 = 10485760 bytes
10 Mb/s is 10 * 1000 * 1000 = 10000000 b/s

Snowknight26
16th January 2009, 04:31
You got it backwards. :\

Sagekilla
16th January 2009, 05:27
If you mean Sparkov, then yes. He should be using bitrate of 6990 kbps (= 50 * 1024 * 1024 * 8 / 60 / 1000 / 1000).

Sparkov
16th January 2009, 10:10
Ah ok, thanks very much - I didn't realise that 1kbps = 1000bps with data transfer; I was using 1024bps.