4
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

FFmpeg コマンドメモ

Posted at

MOV から Windows で再生できる MP4 に変換

ffmpeg -i /path/to/in.mov -pix_fmt yuv420p -strict -2 /path/to/out.mp4

動画の情報を確認

ffprobe /path/to/video

動画をフレームごとの連番画像に変換

ffmpeg -i /path/to/video -q:v 0 -vf scale=1280:-1 /path/to/image_%05d.jpg
  • -q:v 0: 画質を落とさない
  • -vf scale=1280:-1: 画像サイズ変更。 "-1" は等倍

連番画像を動画に変換

ffmpeg -framerate 30 -i /path/to/image_%05d.jpg /path/to/video

動画を切り出し

ffmpeg -ss [開始秒] -i /path/to/in -t [切り出す秒数] [-strict -2] /path/to/out

動画を連結

ffmpeg -i in1.mp4 -i in2.mp4 -filter_complex "concat=n=2:v=1:a=0" out.mp4
  • n は連結する動画数
  • v は映像を連結する(1)か否か(0)
  • a は音声を連結する(1)か否か(0)

動画をリサイズ

ffmpeg -i /path/to/in -s 1280x720 /path/to/out
4
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
2

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?