[FFmpeg-user] Convert gif to mp4 using ffmpeg

Moritz Barsnick barsnick at gmx.net
Thu Mar 10 10:34:55 CET 2016


On Thu, Mar 10, 2016 at 16:20:23 +0700, aris wrote:
> I need to know how to convert gif to mp4 using ffmpeg best quality results ?

Using the image2 demuxer:
https://www.ffmpeg.org/ffmpeg-formats.html#image2-1

Something like
$ ffmpeg -framerate 25 -pattern_type glob -i "*.gif" out.mp4

You may need to play with the quality settings, e.g. "-crf" if your
ffmpeg supports libx264, or "-q:v" for the mpeg4 codec.

(Did you mean mp4 container with such a file extension, or the mpeg4
codec?)

Moritz


More information about the ffmpeg-user mailing list