smallWalk

Really just a technical note for myself. I thought I had written this down somewhere here, but I couldn’t find it, so, here it is.

Converting png to a video in Linux:

ffmpeg -framerate 24 -pattern_type glob -i ‘*.png’ -c:v libx264 -r 30 -pix_fmt yuv420p out.mp4

Setting the framerate sets the speed of the video. You can replace png with jpeg or jpg if needed. This does, of course, require the ffmpeg utility/package.

And, converting png to a GIF in Linux:

convert -delay 10 -loop 0 *.png myimage10.gif

The delay sets the milliseconds of delay between frame, so lower makes a faster video, higher makes a slower video. 8 to 10 seems about right for something that should look “real time”. This requires the imagemagick package.

Linux – keep it simple.

Leave a Reply

Your email address will not be published. Required fields are marked *