ffmpeg note

  1. 1. ffmpeg note

ffmpeg note

  • To Convert video to 720p

    1
    ffmpeg -i input.mp4 -s 1280x720 -b:v 1024k -bufsize 1024k output.avi
  • To set the video bitrate of the output file to 64 kbit/s:

    1
    ffmpeg -i input.avi -b:v 64k -bufsize 64k output.avi
  • To force the frame rate of the output file to 24 fps:

    1
    ffmpeg -i input.avi -r 24 output.avi
  • To remove audio

    1
    2
    3
    # -c:v copy copies the video stream.
    # -an removes the audio stream.
    ffmpeg -i input.mp4 -c:v copy -an output.mp4
  • To cut mp3

1
ffmpeg -i input.mp3 -ss 00:00:00 -t 00:00:01 -acodec copy output.mp3