1

Many informations can be found about that (for example)

I type convert x.pdf x-%03d.png (or jpg result is the same), where x.pdf is two page document and I get file x-%04d.png with first page instead of two files x-000.png and x-001.png. convert x.pdf[1] x.png works properly.

What I'm doing wrong?

$ convert -version
GraphicsMagick 1.3.20 2014-08-16 Q8 http://www.GraphicsMagick.org/
Copyright (C) 2002-2014 GraphicsMagick Group.
Additional copyrights and licenses apply to this software.
See http://www.GraphicsMagick.org/www/Copyright.html for details.

Feature Support:
  Native Thread Safe       yes
  Large Files (> 32 bit)   yes
  Large Memory (> 32 bit)  yes
  BZIP                     yes
  DPS                      no
  FlashPix                 no
  FreeType                 yes
  Ghostscript (Library)    no
  JBIG                     yes
  JPEG-2000                yes
  JPEG                     yes
  Little CMS               yes
  Loadable Modules         no
  OpenMP                   yes (201307)
  PNG                      yes
  TIFF                     yes
  TRIO                     no
  UMEM                     no
  WebP                     no
  WMF                      yes
  X11                      yes
  XML                      yes
  ZLIB                     yes

Host type: x86_64-pc-linux-gnu

Configured using the command:
  ./configure  '--build' 'x86_64-linux-gnu' '--enable-shared' '--enable-static' '--enable-libtool-verbose' '--prefix=/usr' '--mandir=${prefix}/share/man' '--infodir=${prefix}/share/info' '--docdir=${prefix}/share/doc/graphicsmagick' '--with-gs-font-dir=/usr/share/fonts/type1/gsfonts' '--with-x' '--x-includes=/usr/include/X11' '--x-libraries=/usr/lib/X11' '--without-dps' '--without-modules' '--without-frozenpaths' '--with-perl' '--with-perl-options=INSTALLDIRS=vendor' 'build_alias=x86_64-linux-gnu' 'CFLAGS=-Wall -g -fno-strict-aliasing -O2' 'LDFLAGS=' 'CXXFLAGS=-Wall -g -fno-strict-aliasing -O2'

Final Build Parameters:
  CC       = gcc -std=gnu99
  CFLAGS   = -fopenmp -Wall -g -fno-strict-aliasing -O2 -Wall -pthread
  CPPFLAGS = -I/usr/include/X11 -I/usr/include/freetype2 -I/usr/include/libxml2
  CXX      = g++
  CXXFLAGS = -Wall -g -fno-strict-aliasing -O2 -pthread
  LDFLAGS  = -L/usr/lib/X11 -L/usr/lib -L/usr/lib
  LIBS     = -ljbig -llcms2 -ltiff -lfreetype -ljasper -ljpeg -lpng12 -lwmflite -lXext -lSM -lICE -lX11 -llzma -lbz2 -lxml2 -lz -lm -lgomp -lpthread
Community
  • 1
  • 1
Luuuucky
  • 139
  • 1
  • 10
  • 1
    hm, my convert manpage does not lose a word about the %04d option, however if you have ghostscript, I thing that one would support it like `gs -sOutputFile=x-%04d.png -dNOPAUSE -sDEVICE=png16m x.pdf -c quit` Add variables for resolution etc. according to taste – Stefan Hegny May 29 '16 at 17:58
  • on the other hand, your x-%04d.png output filename format works in my convert, very strange. However my version seems to be newer `convert -version Version: ImageMagick 6.7.7-10 2016-04-07 Q16 http://www.imagemagick.org Copyright: Copyright (C) 1999-2012 ImageMagick Studio LLC Features: OpenMP ` – Stefan Hegny May 29 '16 at 19:03
  • with x-0.png, x-1.png, ... x-9.png, x-10.png, ... x-99.png instead of x-000.png, x-001.png, ... x-009.png, x-010.pn, ... x-099.png ; I have got problems. You may ckeck this. – 7Tonin Mar 14 '22 at 20:56

0 Answers0