How to join gifs as sequence, one after the other?

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
stewpid
Posts: 1
Joined: 2015-11-18T11:47:22-07:00
Authentication code: 1151

How to join gifs as sequence, one after the other?

Post by stewpid »

Hi, I've used this software to join images into a gif no problem, but i was trying to join some gifs in the same way and couldn't find how to do it.
Basically I've got some gifs that are the same size and same framerate and want to join them up into one longer gif. I don't want to change the framerate or anything, just join them as one continuous gif playing one after the other.
Is that even possible?

Also, what is the maximum frame delay that can be entered?

Thanks! Nice software!
Last edited by stewpid on 2015-11-18T12:01:21-07:00, edited 1 time in total.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: How to join gifs as sequence, one after the other?

Post by snibgo »

Simply:

Code: Select all

convert in1.gif in2.gif in3.gif out.gif
... for however many inputs you want.

However, you might need to coalesce each input, and may want to optimize the output.

Code: Select all

convert ( in1.gif -layers coalesce ) ( in2.gif -layers coalesce ) in3.gif -layers coalesce ) -layers optimize out.gif
snibgo's IM pages: im.snibgo.com
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: How to join gifs as sequence, one after the other?

Post by fmw42 »

If the frame rates are not the same, it might not look good. See http://www.imagemagick.org/Usage/anim_mods/#merging
Post Reply