Skip to content

Instantly share code, notes, and snippets.

@suhanlee
Last active August 9, 2016 08:03
Show Gist options
  • Save suhanlee/1d89d50c894d04781850d7e1a00f9911 to your computer and use it in GitHub Desktop.
Save suhanlee/1d89d50c894d04781850d7e1a00f9911 to your computer and use it in GitHub Desktop.
ffmpeg command line
$ ffprobe -select_streams v -show_streams -count_frames [input file]
$ ffmpeg -i [input_file]
# fps * duration_time
# 짧은 길이 쪽으로 맞춰서 먹싱
$ ffmpeg -i [input_file] -i [input_file2] -shortest [output_file]
# width = 320, height = 240 지정
$ ffmpeg -i [input_file] -vf scale=320:240 [output_file]
# width = 320 만 지정, height 는 비율 맞춰서 계산
$ ffmpeg -i [input_file] -vf scale=320:-1 [output_file]
# use r option
# r [skip frame]
$ ffmpeg -i [input_file] -r 5 [output_file] # skip 5 frame per second
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment