note 90376 added to function.imagick-blurimage

From: Date: Sun, 19 Apr 2009 01:00:26 +0000
Subject: note 90376 added to function.imagick-blurimage
Groups: php.notes 
Request: Send a blank email to php-notes+get-153475@lists.php.net to get a copy of this message
A pure GD ImageBlur. More at http://www.puremango.co.uk <? function myImageBlur($im) { // w00t. my very own blur function $width = imagesx($im); $height = imagesy($im); $temp_im = ImageCreateTrueColor($width,$height); $bg = ImageColorAllocate($temp_im,150,150,150); // preserves transparency if in orig image ImageColorTransparent($temp_im,$bg); // fill bg ImageFill($temp_im,0,0,$bg); // the higher, the more blurred (no impact on speed) $distance = 1; // blur by merging with itself at different x/y offsets: ImageCopyMerge($temp_im, $im, 0, 0, 0, $distance, $width, $height-$distance, 70); ImageCopyMerge($im, $temp_im, 0, 0, $distance, 0, $width-$distance, $height, 70); ImageCopyMerge($temp_im, $im, 0, $distance, 0, 0, $width, $height, 70); ImageCopyMerge($im, $temp_im, $distance, 0, 0, 0, $width, $height, 70); // remove temp image ImageDestroy($temp_im); return $im; } ?> ---- Server IP: 92.48.74.199 Probable Submitter: 87.194.252.116 ---- Manual Page -- http://www.php.net/manual/en/function.imagick-blurimage.php Edit -- https://master.php.net/note/edit/90376 Del: integrated -- https://master.php.net/note/delete/90376/integrated Del: useless -- https://master.php.net/note/delete/90376/useless Del: bad code -- https://master.php.net/note/delete/90376/bad+code Del: spam -- https://master.php.net/note/delete/90376/spam Del: non-english -- https://master.php.net/note/delete/90376/non-english Del: in docs -- https://master.php.net/note/delete/90376/in+docs Del: other reasons-- https://master.php.net/note/delete/90376 Reject -- https://master.php.net/note/reject/90376 Search -- https://master.php.net/manage/user-notes.php

« previous php.notes (#153475) next »