imagecreatefromgif & imagecolortransparent() ??

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all, the simple code snippet:

header('Content-type: image/gif');
$im = imagecreatefromgif("/path/Mypic.gif");
$background = imagecolorallocate($im, 255, 255, 255);
imagecolortransparent($im,$background);

imagegif($im,'/path/TransparentPic.gif');
imagedestroy($im);


is creating the new image but is not setting the white background to
transparent;
I am sure about the presence of the white color in the background
(checked it with imagecolorat() etc).

a similarly simple test setting transparency on a new image created
with 'imagecreatetruecolor()' works correctly... any hints?!

Cheers, Luca

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux