note 14025 added to function.imagecolorallocate.php
| From: | russellb at caesy dot com | Date: | Fri, 13 Jul 2001 18:00:14 +0000 |
| Subject: | note 14025 added to function.imagecolorallocate.php | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-15346@lists.php.net to get a copy of this message | ||
I had a problem allocating a color. I found I could deallacted a close match then allocate the
color I wanted.
$white = ImageColorClosest($im, 255, 255, 255);
ImageColorDeAllocate($im, $white);
$white = ImageColorAllocate ($im, 255, 255, 255);
You lose the closest color match, but you can allocate what'ever color you wanted in the first
place.
http://www.php.net/manual/en/function.imagecolorallocate.php