ffmpeg commands


# output an image for every second in the video
ffmpeg -i input.flv -vf fps=1 out%d.png



# create tiled image (for every 1000th frame in the video)
ffmpeg -ss 00:00:10 -i movie.avi -frames 1 -vf "select=not(mod(n\,1000)),scale=32:24,tile=2x3" out.png

# convert video to 100k max bit rate
ffmpeg -i inmovie.mp4 -c:v libx264 -b:v 2M -maxrate 100K -bufsize 1M output.mp4

# set frame rate of output video to 24
ffmpeg -i input.avi -r 24 output.avi

# record audio and video from x server using pulse/alsa
ffmpeg -video_size 1024x768 -framerate 25 -f x11grab -i :0.0+100,200 -f pulse -ac 2 -i default output.mkv
ffmpeg -video_size 1024x768 -framerate 25 -f x11grab -i :0.0+100,200 -f alsa -ac 2 -i hw:0 output.mkv