note 29946 rejected from function.imagetruecolortopalette by didou

From: Date: Fri, 15 Aug 2003 22:05:47 +0000
Subject: note 29946 rejected from function.imagetruecolortopalette by didou
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-54260@lists.php.net to get a copy of this message
Note Submitter: niels@myplace.dk ---- The is several known bugs related to this feature. When I use this function on my workstation Apache segfaults. I tried to make a replacement function, only to find related bugs in other functions (or maybe the same bug affecting several functions). This replacement function works for me. function imagetruecolortopalette_(&$img) { $w = imagesx($img); $h = imagesy($img); $img2 = ImageCreate($w, $h); imagecopyresized($img2, $img, 0, 0, 0, 0, $w, $h, $w, $h); $img = $img2; }

« previous php.notes (#54260) next »