Skip to content

Instantly share code, notes, and snippets.

@murano500k
Last active August 19, 2017 08:10
Show Gist options
  • Select an option

  • Save murano500k/b64bc4cc44ca8d9464fb98faebbe9806 to your computer and use it in GitHub Desktop.

Select an option

Save murano500k/b64bc4cc44ca8d9464fb98faebbe9806 to your computer and use it in GitHub Desktop.
rm -rf /tmp/timelapse
mkdir -p /tmp/timelapse
adb pull /sdcard/timelapse/ /tmp/timelapse
export IMAGEPATH=/tmp/timelapse
export VIDEOFILE=~/timelapse/video.avi
mencoder -nosound -ovc lavc -lavcopts \
vcodec=msmpeg4v2:vpass=1 \
-vf scale=1920:1080 -mf type=jpeg:fps=24 \
mf://$IMAGEPATH/*.jpg -o $VIDEOFILE
mencoder -ovc lavc -lavcopts vcodec=msmpeg4v2:vpass=1 -mf w=1920:h=1080:type=jpg:fps=25 -vf scale=1920:1080 \
-o $VIDEOFILE mf://$IMAGEPATH/*.jpg
mencoder -nosound mf://$IMAGEPATH/*.jpg -mf w=800:h=371:type=jpg:fps=25 -ovc lavc -lavcopts \
vcodec=mpeg4:vbitrate=2160000:mbd=2:keyint=132:v4mv:vqmin=3:lumi_mask=0.07:dark_mask=0.2:mpeg_quant:scplx_mask=0.1:tcplx_mask=0.1:naq \
-o $VIDEOFILE
ffmpeg -r 24 -pattern_type glob -i '/media/artem/hddgl/timelapse/*.jpg' -s hd1080 -vcodec libx264 -crf 18 -preset slow ~/timelapse/v3.mp4
ffmpeg -r 24 -pattern_type glob -i '/media/artem/hddgl/timelapse/timelapse/*.jpg' -s hd1080 -vcodec libx264 -crf 18 -preset slow ~/timelapse/v4.mp4
ffmpeg -r 24 -pattern_type glob -i '/tmp/timelapse/*.jpg' -s hd1080 -vcodec libx264 -crf 18 -preset slow ~/timelapse/v3.mp4
ffmpeg -i '/tmp/timelapse/*.jpg' -c:v libx264 -preset slow -profile:v high -crf 18 -coder 1 -pix_fmt yuv420p -movflags +faststart -g 30 -bf 2 -c:a aac -b:a 384k -profile:a aac_low ~/timelapse/v3.mp4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment