note 109286 added to imagick.combineimages

From: Date: Mon, 02 Jul 2012 17:05:27 +0000
Subject: note 109286 added to imagick.combineimages
Groups: php.notes 
Request: Send a blank email to php-notes+get-189011@lists.php.net to get a copy of this message
This will separate out the individual RGB channels and recombine them: <?php $im = new Imagick ("test.jpg"); $red = clone $im; $red->separateImageChannel (imagick::CHANNEL_RED); $green = clone $im; $green->separateImageChannel (imagick::CHANNEL_GREEN); $red->addImage ($green); $green->destroy (); $blue = clone $im; $blue->separateImageChannel (imagick::CHANNEL_BLUE); $red->addImage ($blue); $blue->destroy(); $red->setFirstIterator (); $im_new = $red->combineImages (imagick::CHANNEL_ALL); $im_new->writeImage ("test_rebuilt.png"); echo "<img src=\"test_rebuilt.png\">\r\n"; ?> ---- Server IP: 158.255.214.58 Probable Submitter: 89.182.54.27 ---- Manual Page -- http://www.php.net/manual/en/imagick.combineimages.php Edit -- https://master.php.net/note/edit/109286 Del: integrated -- https://master.php.net/note/delete/109286/integrated Del: useless -- https://master.php.net/note/delete/109286/useless Del: bad code -- https://master.php.net/note/delete/109286/bad+code Del: spam -- https://master.php.net/note/delete/109286/spam Del: non-english -- https://master.php.net/note/delete/109286/non-english Del: in docs -- https://master.php.net/note/delete/109286/in+docs Del: other reasons-- https://master.php.net/note/delete/109286 Reject -- https://master.php.net/note/reject/109286 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#189011) next »