[Resolved] Pause between loops

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
noober
Posts: 4
Joined: 2013-02-03T13:53:06-07:00
Authentication code: 6789

[Resolved] Pause between loops

Post by noober »

I have a lot of *.png files and want to build a single animation. The command I use is the following:

convert -loop 0 -alpha set -dispose previous -delay 0 *.png ani.gif

It works OK, but... there is a pause between loops. Though the pause between frames is very small so everything looks smooth, the pause between loops is about a second.

I built the gif under Windows x64 and tested the gif with Firefox 18 / Google Chrome 24. I want to get rid of this unwanted pause to make the whole animation smooth.

Sorry for possible duplicate, I'm a noob here.

Regards,
Last edited by noober on 2013-02-04T23:47:28-07:00, edited 1 time in total.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Pause between loops

Post by fmw42 »

try

convert -dispose previous -delay 0 *.png -alpha set -loop 0 ani.gif

Most likely it is the viewer. Many viewer have built in minimum delays that you cannot get around.
noober
Posts: 4
Joined: 2013-02-03T13:53:06-07:00
Authentication code: 6789

Re: Pause between loops

Post by noober »

fmw42 wrote:try

convert -dispose previous -delay 0 *.png -alpha set -loop 0 ani.gif
Looks the same.
fmw42 wrote:Most likely it is the viewer. Many viewer have built in minimum delays that you cannot get around.
All the rest of looped gifs work just fine. For instance, the bunny rabbit from the IM tutorial (cleared frames technique section). No visible delay between loops. So, it's something wrong with my command.
noober
Posts: 4
Joined: 2013-02-03T13:53:06-07:00
Authentication code: 6789

Re: Pause between loops

Post by noober »

I want to do something like this:

Image

There is NO delay between the last and the first frames. Now what I get:

Image

There IS a pause at the end of every cycle (when the top vertex is facing "camera" and snake eye is at right). Please help, I tried all options and can't understand how to eliminate the damned interloop delay.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Pause between loops

Post by snibgo »

The problem isn't with the command, but the frames. Take a look at them. Out of 20 frames, how many have "one" on the right? About 5 frames. How many frames have "five" in the same position? One frame.

It looks to me as if the frames weren't generated at a constant rate of rotation. The die accelerates at the start and decelerates at the end.
snibgo's IM pages: im.snibgo.com
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Pause between loops

Post by snibgo »

Just to confirm, I disassembled the animation twice and reassembled all 40 frames into one animation, making it twice as long as yours. Each time the "one" came to the right side, it slowed to a stop, then speeded up. I couldn't see any difference between the end of my animation and the mid-way point.
snibgo's IM pages: im.snibgo.com
noober
Posts: 4
Joined: 2013-02-03T13:53:06-07:00
Authentication code: 6789

Re: Pause between loops

Post by noober »

Oh, I see now. Yep, the problem was with the frames. Thank you.
Post Reply