I'm trying this class and I have several GIFs, all of which have a transparent background. When I display the individual gifs on my web site, they all show up with the background color of the web page. But, when I use this class to process the images into an animated GIF, the background of each image is set to white.
I've tried passing in -1, 0, and the three background colors for the transparency arguments, but the background is still set to white. I'm not sure what I'm doing wrong. Any help would be appreciated. Here is what I'm doing right now for the call:
László Zsidi - 2007-05-06 20:14:55 - In reply to message 5 from Paul Michali
I'm so sorry, I tried to search a soution for your problem, but I could not find for now.
Sorry my free time is very limited for my hobbies, but I don't forget you!
Thought, I will create a transparent pixel found script for GIFEncoder as an extension resolve image transparent troubles.
Paul Michali - 2007-05-08 10:26:25 - In reply to message 6 from László Zsidi
Thanks! I appreciate your help on this. I have a workaround, namely to create a duplicate of each image with the transparent region set to the current background used on the web site.
However, it requires that I have two copies of each image (one for display on pages, where the background color varies, and one with no transparency that is used in the animated GIF). This process more manual (as I need to create the non-transparent version of the image, using the current background color for the page where the image is displayed).
IOW, these images appear individually on pages where the background is white, but they also appear in an amimated GIF, where the background is a shade of blue (currently). The images are all with transparency, and when I use Paint Shop Pro to generate the animated GIF, it works fine.
Unfortunately, when I'm trying to automate the generation the animated GIF, allowing people to add/remove transparent images from the GIF, and then re-building the animated GIF, I'm getting a white background, instead of the transparent background.
I don't know much about the transparent GIFs, so any advice you may have on this would be appreciated!
Corby Johanneson - 2007-09-05 01:26:24 - In reply to message 6 from László Zsidi
Hi guys - I'm having this problem as well. I just can't set the transparency for my merged GIF not matter what I try.
I've looked at my animated GIF file that GIFEncoder Class creates and have found that the color I'm trying to set as the background *is* in fact RGB(252,254,252) - and I've verified that I'm passing that info in the correct order, but no go.
I also noticed that when I load the GIF into two different GIF-Animation programs, they both tell me that the background transparency color has not even been set... this makes me think that I'm doing something wrong, but I'm really not sure. I've looked at the Class code, but it's over my head.
In any case, here's my call to the Constructor:
$gif = new GIFEncoder($frames,$framed,0,2,252, 254, 252,"url");