...: nabster :...


contents

# m2ts2vob.sh # # Converts all m2ts files in the directory to DVD-compatible vobs # Modify bitrates after using an online calculator : http://dvd-hq.info/bitrate_calculator.php # (C) nabster # Distribute under GPL for files in `ls *.m2ts` do filenamewithoutextension=${files%.m2ts} echo echo $filenamewithoutextension # Option 1 - Interpolates frames for smooth 25 fps playback # nice ffmpeg -i $filenamewithoutextension.m2ts -aspect 16:9 -s 720x576 -f yuv4mpegpipe -vcodec pgmyuv - | yuvmotionfps -r 50:1 > temporary.yuv # nice ffmpeg -i $filenamewithoutextension.m2ts -ac 2 -ab 128k -ar 48000 $filenamewithoutextension.ac3 # nice mencoder -nosound -ovc lavc -of mpeg -mpegopts format=dvd:tsaf -vf scale=720:576,harddup -srate 48000 -af lavcresample=48000 -lavcopts vcodec=mpeg2video:vrc_buf_size=1835:vrc_maxrate=9350:vbitrate=6450:keyint=15:vstrict=0:aspect=16/9 -ofps 25 -o $filenamewithoutextension.m2v temporary.yuv # nice ffmpeg -i $filenamewithoutextension.m2v -i $filenamewithoutextension.ac3 -vcodec copy -acodec copy $filenamewithoutextension.vob # rm temporary.yuv # rm $filenamewithoutextension.ac3 # rm $filenamewithoutextenion.m2v # Mencoder-only is ok if the frame rate is 25 or 50 fps # For 90 minutes of 16/9 PAL video and 12kbps audio on a 4.3 Gb disk vrc_maxrate=9350:vbitrate=6450 nice mencoder -oac lavc -ovc lavc -of mpeg -mpegopts format=dvd:tsaf:film2pal -vf scale=720:576,harddup -srate 48000 -af lavcresample=48000 -lavcopts vcodec=mpeg2video:vrc_buf_size=1835:vrc_maxrate=9350:vbitrate=6450:keyint=15:vstrict=0:acodec=ac3:abitrate=192:aspect=16/9:acodec=ac3:abitrate=128 -ofps 25 -o $filenamewithoutextension.vob $filenamewithoutextension.m2ts done chmod og+rw *.vob

No comments:

Post a Comment