11
3
I'm developing android application that converts mp4
files into gifs
using ffmpeg
.
Problem is that generated gifs are huge in size. And another problem is that I can't use anything else than ffmpeg
(e.g.imagemagick
for convert
, or even palletes
for now) to reduce generated gif size.
this is the command I'm using:
ffmpeg -y -i file.mp4 -pix_fmt rgb24 -r 10 -s 320x480 file.gif
So is there any other way to optimize conversion?
5Weirdly, generating a palette tripled the size of the GIF, although it greatly increased the quality over the default palette. I found the best way is to generate the GIF with ffmpeg as per usual (possibly with a better palette as in this answer) then just run it through an optimization tool (there's ones online too) that can make unchanging parts of the frame transparent or apply other optimizations. – Jason C – 2016-10-27T16:48:10.133