PDA

View Full Version : ffmpeg Quality


bryno
29th November 2006, 23:35
Hey guys.

I've been trying tweak ffmpeg's settings to produce GOOD quality with ffmpeg. I have an original clip that has high motion in it, and ffmpeg just turns the video extremely blocky when encoding with MPEG 2. I know it's possible to have better quality with this clip because TMPGEnc is able produce decent quality from it. I'm just dying to know the *ffmpeg way*, or even if ffmpeg can do it. :scared:

With ffmpeg, I can set the lmin to 0 and lmax to QP2LAMBDA, and the quality almost matches TMPGEnc's, but it drives the bitrate up extremely high. If I'm wanting to do decent DVD encoding, this of course isn't acceptable.

Here's a sample screenshot of how TMPGEnc looks to ffmpeg:
TMPGEnc: http://heapify.org/etc/ffm/tmpgenc.png
ffmpeg: http://heapify.org/etc/ffm/ffmpeg.png
Major blocky-ness with ffmpeg :-(

Here is the original clip:
http://heapify.org/etc/ffm/TestforMPG-Short.avi

Encoded with ffmpeg without lmin/lmax settings:
http://heapify.org/etc/ffm/YuckNolminlmax.mpg

Encoded with TMPGEnc, looks *great* as I want ffmpeg's to :-(
http://heapify.org/etc/ffm/TMPGEnc.mpg

Here is how I am invoking ffmpeg:
ffmpeg -i TestforMPG-Short.avi -y -f vob -vcodec mpeg2video -acodec mp2 -ab 384k -ar 48000 -ac 2 -aspect 4:3 -b 7000k -minrate 7000k -maxrate 7000k -bufsize 224KiB -g 12 -bf 2 -flags ildct+ilme+trell -mbd 2 Ugly.mpg

Anyone run into similar quality issues that have been worked out? Any help? :confused:

Blue_MiSfit
30th November 2006, 12:08
Dude, if you want quality, why are you using CBR?

Do 2 passes, and set minrate to like 1000k and keep maxrate at 7000k or whatever.

1 pass CBR will never be a "good quality" solution, unless you throw massive bitrate at it.

Mug Funky
1st December 2006, 01:14
dunno, if max rate is the only constraint (like if you have a short movie to go on a DVD), then CBR is the best quality you can manage - all other techniques will simply lower the bitrate.

of course, CBR types are many and varied, and some work better than others, but theoretically it should be fine.