[MEncoder-users] Bits per block

Federico Zema Federico.Zema at cern.ch
Thu Jul 12 15:33:51 CEST 2007


On Thu, 12 Jul 2007, Grozdan Nikolov wrote:

>                    videobitrate * 1000
> bpb = --------------------------------------
>           fps * ((width * height) / (16 * 16))
> 
> And here's where I get a bit confused. He talks about 2 digit values as 
> outcome (40 and 50 bpb) but when I calculate the bpb value for a 640x480 
> movie with a 25 FPS value and 900 kbps as bitrate, I get huge values as 
> outcome, eg
> 
> echo $(($((900*1000))/25*$((640*480))/$((16*16))))
> 
> and I get 43200000 as outcome. Only if I divide this outcome with 1000000 I 
> get a two digits value (43 in this case)
> 
> So my question is am I the one who's doing something wrong here or is the 
> above formula wrong?

Hi,
 you are missing a couple of double parenthesis:

echo $(($((900*1000))/$((25*$((640*480))/$((16*16))))))
30

 Cheers
 Federico



More information about the MEncoder-users mailing list