title: Convert PDF file to TIFF using imagick from php
body: <p>Hi i got another script to convert a pdf to tiff, this script use imagick library from php, when i execute the next pice of code, got a error, can anyone help me, the code is</p>
  
  <pre><code>&lt;?php
  $im2 = new Imagick("file.pdf");
  $im2-&gt;setImageFormat("tiff");
  $im2-&gt;setImageColorSpace(5); 
  $im2-&gt;writeImage("file.tif");
  ?&gt;
  </code></pre>
  
  <p>the error</p>
  
  <pre><code>Fatal error: Uncaught exception 'ImagickException' with message 'no decode delegate for this image format `PNG' @ error/constitute.c/ReadImage/504'
  </code></pre>
  
  <p>please can anyone tell me what is the problem, reading in the web is something with delegate decode, but is not clear for me, the error is in the line one</p>
  
  <p>Thanks in advance</p>
  
  <p><strong>Update:</strong> </p>
  
  <p><code>convert --version</code> execution</p>
  
  <pre><code>Version: ImageMagick 6.9.4-4 Q16 x86_64 2016-05-23 http://www.imagemagick.org
  Copyright: Copyright (C) 1999-2016 ImageMagick Studio LLC
  License: http://www.imagemagick.org/script/license.php
  Features: Cipher DPC OpenMP
  Delegates (built-in): bzlib freetype jpeg tiff x zlib
  </code></pre>
  
  <p>phpinfo() for imagick</p>
  
  <pre><code>ImageMagick number of supported formats: 217
  
  ImageMagick supported formats: 3FR, A, AAI, AI, ART, ARW, AVI, AVS, B, BGR, BGRA, BGRO, 
  BMP, BMP2, BMP3, BRF, C, CAL, CALS, CANVAS, CAPTION, CIN, CIP, CLIP, CMYK, CMYKA, CR2, 
  CRW, CUR, CUT, DATA, DCM, DCR, DCX, DDS, DFONT, DNG, DPX, DXT1, DXT5, EPDF, EPI, EPS, 
  EPS2, EPS3, EPSF, EPSI, EPT, EPT2, EPT3, ERF, FAX, FITS, FRACTAL, FTS, G, G3, GIF, 
  GIF87, GRADIENT, GRAY, GROUP4, H, HALD, HDR, HISTOGRAM, HRZ, HTM, HTML, ICB, ICO, 
  ICON, IIQ, INFO, INLINE, IPL, ISOBRL, ISOBRL6, JNX, JPE, JPEG, JPG, JPS, JSON, K, 
  K25, KDC, LABEL, M, M2V, M4V, MAC, MAGICK, MAP, MASK, MAT, MATTE, MEF, MIFF, MKV, 
  MONO, MOV, MP4, MPC, MPEG, MPG, MRW, MSL, MSVG, MTV, MVG, NEF, NRW, NULL, O, ORF, OTB, 
  OTF, PAL, PALM, PAM, PANGO, PATTERN, PBM, PCD, PCDS, PCL, PCT, PCX, PDB, PDF, PDFA, 
  PEF, PES, PFA, PFB, PFM, PGM, PICON, PICT, PIX, PJPEG, PLASMA, PNM, PPM, PREVIEW, 
  PS, PS2, PS3, PSB, PSD, PTIF, PWP, R, RADIAL-GRADIENT, RAF, RAS, RAW, RGB, RGBA, RGBO, 
  RGF, RLA, RLE, RMF, RW2, SCR, SCREENSHOT, SCT, SFW, SGI, SHTML, SIX, SIXEL, 
  SPARSE-COLOR, SR2, SRF, STEGANO, SUN, SVG, SVGZ, TEXT, TGA, THUMBNAIL, TIFF, TIFF64, 
  TILE, TIM, TTC, TTF, TXT, UBRL, UBRL6, UIL, UYVY, VDA, VICAR, VID, VIFF, VIPS, VST, 
  WBMP, WMV, WPG, X, X3F, XBM, XC, XCF, XPM, XPS, XV, XWD, Y, YCbCr, YCbCrA, YUV
  </code></pre>
  
  <p>I read the posts, but i don't see the problem, it's the delegate problem, but i don't understand.</p>