pre8の時、2-passエンコード時に「2pass curve failed to converge」 とメッセージを出してエラー終了するようになった。googleで検索すると、 pre8の 既知のバグ のようでした。
*** libavcodec/ratecontrol.c.ORG Wed Aug 9 06:28:55 2006 --- libavcodec/ratecontrol.c Wed Aug 9 07:32:07 2006 *************** *** 911,917 **** --- 911,921 ---- av_free(qscale); av_free(blured_qscale); + #if 0 if(fabs(expected_bits/all_available_bits - 1.0) > 0.01 ){ + #else + if(abs(expected_bits/all_available_bits - 1.0) > 0.01 ){ + #endif av_log(s->avctx, AV_LOG_ERROR, "Error: 2pass curve failed to converge\n"); return -1; }本来はfabs()を使うべき所という事でpre7->pre8時にabs()->fabs() へ修正が入ったようなのですが、かえって悪い影響が出てしまったようです。
rc1以降では問題ありません。
echo 1024 > /proc/sys/dev/rtc/max-user-freq
/sbin/modprobe mga_vid
#! /bin/sh if [ "X$1" = "X-h" -o "X$1" = "X--help" ] then echo "usage : $0 [-t title] [-c chapter] [-x xwidth -y ywidth] [-2] [-vc vcodec] [-vb vbitrate] [-ac acodec] [-ab abitrate] [-f fps] [-al audio_lang] [-sl subtitle_lang] [-of format] [-o outputfile]" echo " -t title : title number(default 1)" echo " -c chapter : chapter(default 1)" echo " -x xwidth -y ywidth : screen size(default 360 240)" echo " -2 : 2-pass encoding(default none)" echo " -vc vcodec : mjpeg,ljpeg,h263,h263p,mpeg4,msmpeg4,msmpeg4v2,wmv1,wmv2,rv10,mpeg1video,mpeg2video,huffyuv,asv1,asv2,ffv1(default mpeg4)" echo " -vb vbitrate : 4-16000 (kbit) (default 800)" echo " -ac acodec : mp2,mp3,ac3,adpcm_ima_wav(default mp3)" echo " -ab abitrate : audio bitrate (kbit) (default 224)" echo " -f fps : frame per second(default 29.97)" echo " -al audio_lang : audio language (default ja,en)" echo " -ai audio_id : audio id" echo " -sl subtitle_lang : subtitle language (default none)" echo " -si subtitle_id : subtitle id " echo " -of format : avi,mpeg (default avi)" echo " -o outputfile : output filename(default dvd2mp4.[avi|mpg])" exit 0 fi # title="1" chapter="1" xwidth="360" ywidth="240" pass="1" vcodec="mpeg4" vbitrate="800" acodec="mp3" abitrate="224" fps="29.97" alang="ja" aid="" slang="" sid="" format="avi" ext="avi" outputfile="dvd2mp4" # while [ $# != 0 ] do case $1 in -t ) shift title="$1" ;; -c ) shift chapter="$1" ;; -x ) shift xwidth="$1" ;; -y ) shift ywidth="$1" ;; -2 ) pass="2" ;; -vc ) shift vcodec="$1" ;; -vb ) shift vbitrate="$1" ;; -ac ) shift acodec="$1" ;; -ab ) shift abitrate="$1" ;; -f ) shift fps="$1" ;; -al ) shift alang="$1" ;; -ai ) shift aid="$1" ;; -sl ) shift slang="$1" ;; -si ) shift sid="$1" ;; -of ) shift format="$1" ;; -o ) shift outputfile="$1" ;; * ) ;; esac shift done # if [ "X${format}" = "Xavi" ] then ext="avi" else ext="mpg" fi # if [ "X${alang}" = "X" ] then alang_opt="" else alang_opt="-alang ${alang}" fi # if [ "X${aid}" = "X" ] then aid_opt="" else aid_opt="-aid ${aid}" fi # if [ "X${slang}" = "X" ] then slang_opt="" else slang_opt="-slang ${slang}" fi # if [ "X${sid}" = "X" ] then sid_opt="" else sid_opt="-sid ${sid}" fi # if [ "X${acodec}" = "Xmp3" ] then oac="mp3lame" audio_lameopts="-lameopts br=${abitrate}" audio_lavcopts="" else oac="lavc" audio_lameopts="" audio_lavcopts=":acodec=${acodec}:abitrate=${abitrate}" fi # if [ "X${pass}" = "X1" ] then mencoder dvd://${title} -chapter ${chapter} -oac ${oac} ${audio_lameopts} -ovc lavc -lavcopts vcodec=${vcodec}:vhq:vbitrate=${vbitrate}${audio_lavcopts} -ofps ${fps} -zoom -vf scale=${xwidth}:${ywidth} ${alang_opt} ${aid_opt} ${slang_opt} ${sid_opt} -of ${format} -o ${outputfile}.${ext} else mencoder dvd://${title} -chapter ${chapter} -oac ${oac} ${audio_lameopts} -ovc lavc -lavcopts vcodec=${vcodec}:vhq:vbitrate=${vbitrate}:vpass=1${audio_lavcopts} -ofps ${fps} -zoom -vf scale=${xwidth}:${ywidth} ${alang_opt} ${aid_opt} ${slang_opt} ${sid_opt} -of ${format} -o /dev/null mencoder dvd://${title} -chapter ${chapter} -oac ${oac} ${audio_lameopts} -ovc lavc -lavcopts vcodec=${vcodec}:vhq:vbitrate=${vbitrate}:vpass=2${audio_lavcopts} -ofps ${fps} -zoom -vf scale=${xwidth}:${ywidth} ${alang_opt} ${aid_opt} ${slang_opt} ${sid_opt} -of ${format} -o ${outputfile}.${ext} fi # exit 0
*** ./common/mp4v2/mpeg4ip.h.ORG 2011-09-05 22:49:45.047000418 +0900 --- ./common/mp4v2/mpeg4ip.h 2011-09-05 22:51:08.862000418 +0900 *************** *** 123,129 **** --- 123,131 ---- #ifdef __cplusplus extern "C" { #endif + #if 0 char *strcasestr(const char *haystack, const char *needle); + #endif #ifdef __cplusplus } #endif