Complex Image Output Sequence Filename

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
tonyrocks
Posts: 2
Joined: 2011-03-04T15:24:46-07:00
Authentication code: 8675308

Complex Image Output Sequence Filename

Post by tonyrocks »

HI,

I'm converting Multiple page PDFs to individual GIF files. I'm using this syntax:

convert $destfile.pdf $destfile%02d.gif

which yields:
filename00.gif
filename01.gif
....
filename010.gif.

The problem is that I'm trying to make it out put like this:

filename001.gif
filename002.gif
....
filename010.gif
filename011.gif
....

I would like the image filename sequence to start at 1, not 0, and have 3 number places. I thought this would work: convert $destfile.pdf $destfile%03d.gif, but for one it doesn't let me start at 1.

Any ideas?
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: Complex Image Output Sequence Filename

Post by magick »

Add -scene 1 to your command line (just before the output filename).
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: Complex Image Output Sequence Filename

Post by anthony »

See IM examples, Writing Multiple Images, Starting (Scene) Number
http://www.imagemagick.org/Usage/files/#scene
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
Post Reply