Difference between revisions of "Video Tools"
From RobolaboWiki
(Created page with "<h1> Convert MTS to AVI </h1> <pre> ffmpeg -i <INPUT_FILE.mts> -threads 2 -deinterlace -f avi -r 25 -vcodec libxvid -vtag XVID \ -aspect 16:9 -maxrate 1800k -b 1500k -qmin...") |
|||
Line 1: | Line 1: | ||
+ | |||
+ | |||
<h1> Convert MTS to AVI </h1> | <h1> Convert MTS to AVI </h1> | ||
Line 5: | Line 7: | ||
-aspect 16:9 -maxrate 1800k -b 1500k -qmin 3 -qmax 5 -bufsize 4096 -mbd 2 -bf 2 -trellis -aic \ | -aspect 16:9 -maxrate 1800k -b 1500k -qmin 3 -qmax 5 -bufsize 4096 -mbd 2 -bf 2 -trellis -aic \ | ||
-cmp 2 -subcmp 2 -g 300 -acodec libmp3lame -ar 48000 -ab 128k -ac 2 <OUTPUT_FILE.avi> | -cmp 2 -subcmp 2 -g 300 -acodec libmp3lame -ar 48000 -ab 128k -ac 2 <OUTPUT_FILE.avi> | ||
+ | </pre> | ||
+ | |||
+ | <h1> From Simulator to AVI </h1> | ||
+ | <h2> PPM to PNG </h2> | ||
+ | <h3> Same dir </h3> | ||
+ | |||
+ | <pre> | ||
+ | for f in *.ppm; do f2=`basename "$f" ppm`png; echo "$f -> $f2"; convert "$f" "$f2"; done | ||
+ | </pre> | ||
+ | |||
+ | <h3> Other dir </h3> | ||
+ | <pre> | ||
+ | # Type on Origin, where ppm's are | ||
+ | for f in *.ppm; do f2=`basename "$f" ppm`png; echo "$f -> $f2"; convert "$f" <ending_directory>/"$f2";done | ||
+ | </pre> | ||
+ | |||
+ | <h2> PNG to MPEG4 </h2> | ||
+ | <h3> Same dir </h3> | ||
+ | <pre> | ||
+ | mencoder mf://*.png -mf w=800:h=600:fps=25:type=png -ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell -oac copy -o output.avi | ||
+ | </pre> | ||
+ | |||
+ | <h3> Other dir </h3> | ||
+ | <pre> | ||
+ | # Type on Origin, where png's are | ||
+ | mencoder mf://*.png -mf w=800:h=600:fps=25:type=png -ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell -oac copy -o <ending-directory>/output.avi | ||
+ | </pre> | ||
+ | |||
+ | <h3> Other info </h3> | ||
+ | <pre> | ||
+ | http://www.mplayerhq.hu/DOCS/HTML/en/menc-feat-enc-images.html | ||
+ | http://www.tevs.eu/blog_8.html | ||
</pre> | </pre> |
Revision as of 15:09, 1 June 2012
Contents
Convert MTS to AVI
ffmpeg -i <INPUT_FILE.mts> -threads 2 -deinterlace -f avi -r 25 -vcodec libxvid -vtag XVID \ -aspect 16:9 -maxrate 1800k -b 1500k -qmin 3 -qmax 5 -bufsize 4096 -mbd 2 -bf 2 -trellis -aic \ -cmp 2 -subcmp 2 -g 300 -acodec libmp3lame -ar 48000 -ab 128k -ac 2 <OUTPUT_FILE.avi>
From Simulator to AVI
PPM to PNG
Same dir
for f in *.ppm; do f2=`basename "$f" ppm`png; echo "$f -> $f2"; convert "$f" "$f2"; done
Other dir
# Type on Origin, where ppm's are for f in *.ppm; do f2=`basename "$f" ppm`png; echo "$f -> $f2"; convert "$f" <ending_directory>/"$f2";done
PNG to MPEG4
Same dir
mencoder mf://*.png -mf w=800:h=600:fps=25:type=png -ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell -oac copy -o output.avi
Other dir
# Type on Origin, where png's are mencoder mf://*.png -mf w=800:h=600:fps=25:type=png -ovc lavc -lavcopts vcodec=mpeg4:mbd=2:trell -oac copy -o <ending-directory>/output.avi
Other info
http://www.mplayerhq.hu/DOCS/HTML/en/menc-feat-enc-images.html http://www.tevs.eu/blog_8.html