0

ffmpeg + gifsicle + giflossy + ImageMagick = GIFs From Videos in Linux

Here’s a simple setup and a readymade script for converting MP4s (or WEBMs) to animated GIFs, form Ubuntu 16.04 or Fedora 25:

I started making some .gifs to embed in documentation and my notes as I develop Rusty Nail. I always have to lookup how to convert the images to gifs. Everytime I am also concerned with how big the .gifs are so after doing some looking around I made a little script which uses ffmpeg, convert, and gifsicle (with giflossy) to take an input mp4, webm, or any video that ffmpeg can decode.

The process is this:

    ffmpeg splits the video into a directory of gifs
    convert those images and stitches them together into one gif.
    gifsicle optimizes the gif and allow a stage to resize it and also change the color. The giflossy plug-in also can apply lossy compression to the gif video during the optimization step.

Thanks Drew for sending this in!


Join 5,000+ makers on Adafruit’s Discord channels and be part of the community! http://adafru.it/discord

CircuitPython in 2018 – Python on Microcontrollers is here!

Have an amazing project to share? Join the SHOW-AND-TELL every Wednesday night at 7:30pm ET on Google+ Hangouts.

Join us every Wednesday night at 8pm ET for Ask an Engineer!

Follow Adafruit on Instagram for top secret new products, behinds the scenes and more https://www.instagram.com/adafruit/


Maker Business — A journey through Shenzhen, the electronics manufacturing hub of the world

Wearables — Ice, ice baby

Electronics — Current limiting!

Biohacking — Grindfest 2018

Python for Microcontrollers — CRICKITs are coming!

Get the only spam-free daily newsletter about wearables, running a "maker business", electronic tips and more! Subscribe at AdafruitDaily.com !



No Comments

No comments yet.

Sorry, the comment form is closed at this time.