[FFmpeg-user] problems when updated the r-26400 version to the latest git version

Jim Worrall coniophora at gmail.com
Fri Jul 20 14:30:09 CEST 2012


On Jul 19, 2012, at 1:46 AM, 韩瑞松 wrote:

> I used to use ffmpeg version r-26400 that is the svn-version
> I encode videos into x264 + faac with the command as follow:
> 
> Now,I want to upgrade my ffmpeg to the latest git version.
> I found there is no preset named fastfirstpass or normal.So I copy the options in this to file.I get result as follow:
> 
> command:
>    ffmpeg -y -i youku.mp4 -analyzeduration 2G -pass 1 -vcodec libx264 -flags +loop -cmp +chroma -partitions -parti8x8-parti4x4-partp8x8-partp4x4-partb8x8 -me_method dia -subq 2 -me_range 16 -g 250 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -b_strategy 1 -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -bf 3 -refs 1 -directpred 3 -trellis 0 -flags2 -bpyramid-wpred-mixed_refs-dct8x8+fastpskip+mbtree -wpredp 2 -b 512k -s 576x312 -aspect 576:312 -r 25 -psnr -an -vf setpts=0.5*PTS -af atempo=2 -f flv -map_chapters -1 -g 50 /dev/null
> 
> Unrecognized option 'directpred'
> Failed to set value '3' for option 'directpred'
> 
> command:
>    ffmpeg -y -i youku.mp4 -analyzeduration 2G -pass 1 -vcodec libx264 -flags +loop -cmp +chroma -partitions -parti8x8-parti4x4-partp8x8-partp4x4-partb8x8 -me_method dia -subq 2 -me_range 16 -g 250 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -b_strategy 1 -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -bf 3 -refs 1 -trellis 0 -flags2 -bpyramid-wpred-mixed_refs-dct8x8+fastpskip+mbtree -wpredp 2 -b 512k -s 576x312 -aspect 576:312 -r 25 -psnr -an -vf setpts=0.5*PTS -af atempo=2 -f flv -map_chapters -1 -g 50 /dev/null
> 
> Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height
> 
> How can I use the lastest version ffmpeg to encode videos as the version r-26400 with 2-pass model?
> 
In the ffmpeg command line, you can use -vprofile and -preset to control those options in x264.
You can type "x264 --fullhelp" to see what those options are (--profile and --preset).
Some combination of these should get you what you want.
You can also use -x264opts to specify additional options in x264.  For example,
part of a command line I sometimes use is
-c:v libx264 -vprofile main -preset slower -x264opts level=3.1:crf=17 
Unless you are a real x264 expert, it's better to control these high-level settings and let 
them dictate the low-level settings.  
Jim


More information about the ffmpeg-user mailing list