note 89210 added to function.imagick-setimageformat

From: Date: Thu, 26 Feb 2009 14:54:53 +0000
Subject: note 89210 added to function.imagick-setimageformat
Groups: php.notes 
Request: Send a blank email to php-notes+get-151170@lists.php.net to get a copy of this message
I had a problem when using $im->setImageFormat('jpeg'); Image colors got inverted when i converted pdfs to jpg thumbs. Had to add $im->setImageColorspace(255); to solve it. // read page 1 $im = new imagick( 'test.pdf[ 0]' ); // convert to jpg $im->setImageColorspace(255); $im->setCompression(Imagick::COMPRESSION_JPEG); $im->setCompressionQuality(60); $im->setImageFormat('jpeg'); //resize $im->resizeImage(290, 375, imagick::FILTER_LANCZOS, 1); //write image on server $im->writeImage('thumb.jpg'); $im->clear(); $im->destroy(); ---- Server IP: 89.248.170.61 Probable Submitter: 195.86.222.234 ---- Manual Page -- http://www.php.net/manual/en/function.imagick-setimageformat.php Edit -- https://master.php.net/note/edit/89210 Del: integrated -- https://master.php.net/note/delete/89210/integrated Del: useless -- https://master.php.net/note/delete/89210/useless Del: bad code -- https://master.php.net/note/delete/89210/bad+code Del: spam -- https://master.php.net/note/delete/89210/spam Del: non-english -- https://master.php.net/note/delete/89210/non-english Del: in docs -- https://master.php.net/note/delete/89210/in+docs Del: other reasons-- https://master.php.net/note/delete/89210 Reject -- https://master.php.net/note/reject/89210 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#151170) next »