2

On a 2 minute clip:

ffmpeg.exe -pass 1 -passlogfile pass.log -i E002.avi -b 368k -maxrate 1000k -ab 62 -y out.webm ffmpeg.exe -pass 2 -passlogfile pass.log -i E002.avi -b 368k -maxrate 1000k -ab 62 -y out.webm

the bitrate still goes up to 2mbps. I tryed with -qscale 24 and it does the same thing.

edit

log: frame= 1323 fps= 20 q=0.0 size= 12348kB time=55.22 bitrate=1831.8kbits/s

Sirber
  • 3,358
  • 5
  • 25
  • 32

2 Answers2

2

-g 320 -qmax 63 seemed to do it!

'-g gop_size' Set the group of pictures size. default: 12

'-qmax q' maximum video quantizer scale (VBR)

Sirber
  • 3,358
  • 5
  • 25
  • 32
0

I got error when tried to specify qmax:

[NULL @ 0x641230]Value 63.000000 for parameter 'qmax' out of range
Invalid value '63' for option 'qmax'

I tried to specify bitrate explicitly while converting the 278kbit/s wmv video into webm using two passes, but still, the resulting bitrate was way higher (413kbit/s) than what I have requested (250+32 = 282kbit/s):

ffmpeg -i $Source -b 250k -pass 1 -ab 32k -aq 80 $Target
ffmpeg -y -i $Source -b 250k -pass 2 -ab 32k -aq 80 $Target

What can be done to improve the webm encoding rate control?

Arie Skliarouk
  • 423
  • 2
  • 11
  • get the latest ffmpeg build. I don't remember where to get the latest build, but here's one not too old: http://code.google.com/p/bencos/source/browse/#svn%2Ftrunk%2Fout%2Fffmpeg_win32 be shure to get all the files. – Sirber Apr 28 '11 at 16:03