Register now and start sharing your code snippets.

Create a thumbnail of a movie.

Shell Script (Bash) posted about 1 year ago by marko

Create a thumbnail that is 320 wide by 240 high and five seconds into the movie.

   1  ffmpeg -i mymovie.avi -f mjpeg -t 0.001 -ss 5 -s "320x240" mymovie.jpg

Tagged thumbnail, movie, ffmpeg, jpg

Add duration metadata into flv movie

Shell Script (Bash) posted about 1 year ago by marko

By default an flv movie doesn’t contain the duration metadata. Using the flvtool2 program it is injected like this into the movie file.

   1  cat mymovie.flv | flvtool2 -U stdin mymovie.flv

Tagged flv, movie, flash, duration, metadata, flvtool2

Create an flv movie

Shell Script (Bash) posted about 1 year ago by marko

Create an flv movie that is 320 wide by 240 high. For audio functionality ffmpeg needs to be compiled with the following parameters:

   1  --enable-amr_nb 
   2  --enable-amr_nb-fixed 
   3  --enable-amr_wb 
   4  --enable-mp3lame 

The snippet itself:

   1  ffmpeg -i mymovie.avi -s 320x240 -ar 44100 -r 12 mymovie.flv

Tagged flv, movie, audio, ffmpeg, flash