Skip to content

Instantly share code, notes, and snippets.

@kjunichi
Last active November 21, 2024 13:31
Show Gist options
  • Save kjunichi/a451b3872e68caff7c6313bd329b099f to your computer and use it in GitHub Desktop.
Save kjunichi/a451b3872e68caff7c6313bd329b099f to your computer and use it in GitHub Desktop.

ffmpegでYouTubeショートサイズに変換改良

既知の問題

以下のコマンドでは、SDクオリティでショートになってしまった。

ffmpeg -i MaxxisReaverでグラベルを走った.mp4 -vf crop="607:1080:657:0" -aspect 9:16 out.mp4

再整理

AceProの動画サイズ:1920x1080

1920x1080 を左右切り取り、拡大して1080x1920にしないといけない。

10801.77 ~= 1920 9:16 9/16=0.5625 10800.5625=607.5

603x1072 がアスペクト比が崩れないサイズの組み合わせ

AceProの生のデータはもっと大きかった。。 3840 × 2160

1206 * 2144

ffmpeg -i  -vf crop="1206:2144:1317:6" -aspect 9:16 ume2.mp4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment