Page 1 of 1

Animation loop question

Posted: 2007-08-27T13:48:34-07:00
by metsfan666
I'm trying to set up an animation that does the following:

Displays a sequence of 4 frames 4 times. Then displays a single frame and then restarts from the beginning. I've tried many different ways but can't get it exactly right.
So for example, my first image is like

convert -delay 25 image1.gif image2.gif image3.gif image4.gif -loop 4 output.gif

This creates output.gif that displays each image in order 4 times total.

Then I try this:

convert output.gif -delay 300 oneframe.gif -loop final.gif

I'd expect this to take the first image of 16 cycles, then tack onto the end oneframe.gif. This however is not what happens. final.gif is an image that displays the first 4 frames then my final oneframe.gif and then restarts from the beginning.

Any suggestions?

Re: Animation loop question

Posted: 2007-08-27T23:59:13-07:00
by anthony
GIF animation can NOT loop in the middle.

To do what you want you will need to unroll your loop.

Code: Select all

   convert output.gif \
               \( -clone 0--1 \) \( -clone 0--1 \) -delay 300 oneframe.gif \
               -loop 0 final.gif