Last active
September 20, 2018 05:23
-
-
Save cygmris/2e3c0ebd5b8c5269721a34e4867cf6da to your computer and use it in GitHub Desktop.
ffmpeg_scale_with_remaining.sh
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 | |
| for i in $(ls *.jpg) | |
| do | |
| ffmpeg -i $i -vf "scale=800:-1:force_original_aspect_ratio=decrease" output$i.jpg | |
| done |
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 | |
| for i in $(ls *.mp4) | |
| do | |
| ffmpeg -i $i -vf "scale=320x240:force_original_aspect_ratio=decrease,pad=320:240:(ow-iw)/2:(oh-ih)/2" output$i.mp4 | |
| done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment