Created
February 29, 2016 09:36
-
-
Save danielepolencic/171f1cc6695849be90d7 to your computer and use it in GitHub Desktop.
Rotate videos (container only)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
shopt -s nullglob | |
mov=( IMG_5097 IMG_5102 IMG_5136 IMG_5142 IMG_5158 IMG_5198 IMG_5230 IMG_5231 IMG_5296 IMG_5318 IMG_5323 IMG_5330 IMG_5339 IMG_5348 IMG_5370 IMG_5376 IMG_5380 IMG_5381 IMG_5450 IMG_5451 IMG_5491 IMG_5519 IMG_5536 IMG_5759 ) | |
for f in "${mov[@]}" | |
do | |
echo "Processing $f" | |
ffmpeg -i "${f}.mov" -c copy -metadata:s:v:0 rotate=-90 "${f}_rot.mp4" | |
rm -rf "${f}.mov" | |
mv "${f}_rot.mp4" "${f}.mp4" | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment