IMagick is a native PHP extension to create and modify images using the ImageMagick API. ImageMagick Studio LLC did not write nor does it maintain the IMagick extension, however, IMagick users are welcome to discuss the extension here.
The command I'm using at CLI is: convert -density 360 file.pdf file.jpg
Also, the background changes from white to pink with Imagick code above (but not at CLI), do you need to set additional properties to keep the background colour the same?
Last edited by el_supremo on 2010-02-12T09:54:27-07:00, edited 1 time in total.
Sorry, my ISP shutdown all personal webspace so my MagickWand Examples in C is offline.
See my message in this topic for a link to a zip of all the files.
Sorry, my ISP shutdown all personal webspace so my MagickWand Examples in C is offline.
See my message in this topic for a link to a zip of all the files.
I don't know how to use IMagick but what you need to do is instantiate the $im object without reading the image. Set the density and then read in the image. This will then do things in the same order as the command line which sets the density before the image is read in.
I'm guessing at the syntax but you need something like this:
$im = new Imagick();
$im->setOption('density', '360');
$im->Read('flyer-from-illustrator.pdf');
Pete
Sorry, my ISP shutdown all personal webspace so my MagickWand Examples in C is offline.
See my message in this topic for a link to a zip of all the files.