[MPlayer-users] mencoder failing to encode at desired bitrate/filesize
Ed Sweetman
safemode at comcast.net
Sat May 27 19:02:19 CEST 2006
Dominik 'Rathann' Mierzejewski wrote:
> On Saturday, 27 May 2006 at 12:28, 陆然 wrote:
>
>> Hi,
>>
>> On Saturday 27 May 2006 10:49, Ed Sweetman wrote:
>>
>>> Every now and then I get a video source that simply refuses to encode
>>> over a seemingly random bitrate, no matter what I set it at. I've seen
>>> this happen with the xvid codec and ffmpeg's mpeg4 codec (those are the
>>> two I use). Nothing seems to be special about these files. I was just
>>> wondering if anyone else has seen this problem, where mencoder wont
>>> encode over some arbituary bitrate, no matter what the value on the
>>> command line is.
>>>
>> I've seen similar problems. Once I decided to encoding 12 videos, all captured
>> by a dv with almost the same setting, and I use mencoder with xvid and
>> libavcodecs, there are two of them cannot be encoded with the bitrate I set,
>> (I want a 1500 kbps, but the encoding always resulted at about 700~800
>> kbps). I tried fiddle with different options but no success, ended up
>> encoding it on a windows with virtualdub and xvid :(
>>
>
> If mencoder maxes out below your target bitrate it simply means it doesn't
> need any more bits to encode your video (i.e. using the lowest quantizer).
> There's no point in artificially inflating the bitrate because the quality
> won't increase.
>
> Show us the command line you used and we may be able to say more.
>
> Regards,
> R.
>
>
I'm not encoding at a "quality setting" i'm encoding at a bitrate
setting, so if mencoder is refusing to encode at that bitrate, and the
bitrate is valid, then that is a problem, either with the codec, or with
the encoder.
mencoder -sws 10 -vf pullup,softskip,crop=720:352:0:66,scale=640:-2
-ofps 24000/1001 -oac copy -ovc xvid -xvidencopts
pass=1:bitrate=-409600:vhq=4 -o /dev/null some.vob; mencoder -sws 10
-vf pullup,softskip,crop=720:352:0:66,scale=640:-2 -ofps 24000/1001 -oac
mp3lame -lameopts abr:br=112:aq=0 -ovc xvid -xvidencopts
pass=2:bitrate=-409600:vhq=4 -o test1.avi some.vob;
Results in a file that is about 350MB instead of the ~400 that the rest
all encoded at. Audio and video is complete in the avi, bitrate is
about 300kbit/sec lower than the other files for video, audio is the same.
Same exact command line used for the others, same runtime same
dimensions and same source bitrate.
I too, have had this happen numerous times before over the years and
have had to use a different encoder to get it done. It would be
interesting to see if maybe anyone not using mencoder has had this
happen. That would narrow down the search for the cause.
More information about the MPlayer-users
mailing list