Trouble Converting PDF to TIFF

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
sl4184
Posts: 2
Joined: 2018-12-20T21:09:27-07:00
Authentication code: 1152

Trouble Converting PDF to TIFF

Post by sl4184 » 2018-12-20T21:16:04-07:00

Hello,

I'm using Version: ImageMagick 7.0.8-16 Q16 x86_64 2018-12-10 of ImageMagick on Mac in the terminal app and am having trouble converting a pdf to tiff. I keep inputting this code:

Code: Select all

magick convert -density 300 cookies_recipes2.pdf -depth 8 -strip -background white -alpha off cookies.tiff
and I keep getting this message:

Code: Select all

convert: FailedToExecuteCommand `'gs' -sstdout=%stderr -dQUIET -dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=500000000 -dAlignToPixels=0 -dGridFitTT=2 '-sDEVICE=pngalpha' -dTextAlphaBits=4 -dGraphicsAlphaBits=4 '-r300x300'  '-sOutputFile=/var/folders/kk/bsm199sn5ts3_g71yrrsg4sh0000gn/T/magick-25732sR0jylOlAqYf%d' '-f/var/folders/kk/bsm199sn5ts3_g71yrrsg4sh0000gn/T/magick-25732Rs1mLSNeH3YC' '-f/var/folders/kk/bsm199sn5ts3_g71yrrsg4sh0000gn/T/magick-25732a2ot71X7vOq6'' (1) @ error/pdf.c/InvokePDFDelegate/290.
convert: no images defined `cookies.tiff' @ error/convert.c/ConvertImageCommand/3300.
I've also tried putting in the code without "magick" in front and I've also tried just:

Code: Select all

magick convert cookies_recipes2.pdf cookies.tiff
and still nothing happens.

I appreciate the help. Thank you.

User avatar
fmw42
Posts: 25274
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Trouble Converting PDF to TIFF

Post by fmw42 » 2018-12-20T21:18:08-07:00

Do you have Ghostscript installed? If not, then you need to install it. If so, then you likely need to edit your policy.xml file to enable the reading of PDF/EPS/etc. See https://stackoverflow.com/questions/528 ... 3#52863413 and https://imagemagick.org/script/resources.php

Note on IM 7, use magick, not magick convert and not convert. Otherwise, you may get IM 6 behavior. Other tools, such as identify, mogrify, montage do need to be prefaced by magick, but not convert.

sl4184
Posts: 2
Joined: 2018-12-20T21:09:27-07:00
Authentication code: 1152

Re: Trouble Converting PDF to TIFF

Post by sl4184 » 2018-12-21T13:46:26-07:00

Thank you! Installing GhostScript worked

Post Reply