Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I am trying to convert this image,, to a series of .png files.

This was pretty simple, I used the convert command in Linux,

convert  Dijkstra_Animation.gif dijkstra.png

The command went fine and produced the 27 frames, as reported at the bottom of original page.

However, I find that some of the produced .png files are only single numbers or arrows. Which is different from what I expected.

I want the .png files to be a simple sequence in the same way the .gif file is showing. Could you please suggest a method (in Linux please) to achieve this?


share|improve this question
up vote 14 down vote accepted

Using the -coalesce option will do the wonder.

Like this,

convert -verbose -coalesce Dijkstra_Animation.gif dijkstra.png

Actually the -coalesce option "merges a sequence of images" as is claimed in the manual page.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.