Last active
October 7, 2016 17:32
-
-
Save javikalsan/59d5d38133405c7f0ad4067cc7239b8d to your computer and use it in GitHub Desktop.
Timelapse with avconv
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 | |
# rename photos | |
a=1 | |
for i in *.JPG; do | |
new=$(printf "%04d.JPG" ${a}) #04 pad to length of 4 | |
mv ${i} ${new} | |
let a=a+1 | |
done | |
# create the video | |
avconv -r 10 -i %04d.JPG -r 10 -vcodec libx264 -crf 20 -g 15 -vf scale=1280:720 timelapse.mp4 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment