Skip to content

Instantly share code, notes, and snippets.

@ksarna
Forked from cfr/devert
Created April 2, 2017 21:30
Show Gist options
  • Save ksarna/816191fc9f031c56cf1326fb100bc1e6 to your computer and use it in GitHub Desktop.
Save ksarna/816191fc9f031c56cf1326fb100bc1e6 to your computer and use it in GitHub Desktop.
Fix vertical video
#!/usr/bin/env sh
# http://stackoverflow.com/a/30819570/187663
ffmpeg -i $1 -lavfi '[0:v]scale=ih*16/9:-1,boxblur=luma_radius=min(h\,w)/20:luma_power=1:chroma_radius=min(cw\,ch)/20:chroma_power=1[bg];[bg][0:v]overlay=(W-w)/2:(H-h)/2,crop=h=iw*9/16' $1.fixed.mov
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment