Stitching Pictures Into a Time Lapse: Difference between revisions

From Open Source Ecology
Jump to navigation Jump to search
No edit summary
Line 8: Line 8:
Use Terminal. Navigate to directory with pictures. Then type:
Use Terminal. Navigate to directory with pictures. Then type:


Note that filaname.avi is the output file name.
Note: # -q:v can get a value between 2-31. 2 is best quality and bigger size, 31 is worst quality and least size)
==Using ffmpeg==
<pre>
sudo apt-get install ffmpeg
ffmpeg -r 25 -pattern_type glob -i '*.JPG' -c:v mjpeg -q:v 2 filename.avi
ffmpeg -r 25 -pattern_type glob -i '*.JPG' -c:v mjpeg -q:v 2 filename.avi
</pre>


Note that filaname.avi is the output file name.
==Using avconv==
 
Some versions of debian/ubuntu don't have ffmpeg; the use avlib instead. This process is 2-step, as avconv will not take the '*" glob.


Note: # -q:v can get a value between 2-31. 2 is best quality and bigger size, 31 is worst quality and least size)
<pre>
sudo apt-get install libav-tools
ls *.jpg| awk 'BEGIN{ a=0 }{ printf "mv %s imageToStich%04d.jpg\n", $0, a++ }' | bash
avconv -y -r 25 -i imageToStich%4d.jpg -r 25 -vcodec libx264 -q:v 3 filename.mp4
</pre>

Revision as of 18:20, 5 June 2018

Reference

ffmpeg does it

https://ubuntuforums.org/showthread.php?t=2022316

Howto

Use Terminal. Navigate to directory with pictures. Then type:

Note that filaname.avi is the output file name. Note: # -q:v can get a value between 2-31. 2 is best quality and bigger size, 31 is worst quality and least size)

Using ffmpeg

sudo apt-get install ffmpeg
ffmpeg -r 25 -pattern_type glob -i '*.JPG' -c:v mjpeg -q:v 2 filename.avi

Using avconv

Some versions of debian/ubuntu don't have ffmpeg; the use avlib instead. This process is 2-step, as avconv will not take the '*" glob.

sudo apt-get install libav-tools
ls *.jpg| awk 'BEGIN{ a=0 }{ printf "mv %s imageToStich%04d.jpg\n", $0, a++ }' | bash
avconv -y -r 25 -i imageToStich%4d.jpg -r 25 -vcodec libx264 -q:v 3 filename.mp4