lazy reply on my part, but try playing around with some of the scripts from my website. In it there is a page titled PHP -- Image Processing where I discuss what I have learned so far with GD. I am still expanding it and scanning for errors, but I think a lot of what you are looking for is listed there and there are a lot of sample scripts that you can try and adapt for your own purposes.
If you do find something useful there please post it here so others can see the solution as well. I am still learning, but I am about ready to start learning about some other aspects of PHP such as php.ini files or more on PCRE syntax.
EDIT: I had to sleep. Long day/night at work. Anyway, look at the following:
Code:
<?php
header('Content-type: image/jpeg');
$filename = 'http://www.animeviews.com/images/screenshots/cowboybebop27.JPG';
$im = imagecreatefromjpeg($filename);
imagetruecolortopalette($im, false, 255);
$ig = imagecolorat($im, 20, 20);
imagecolorset($im, $ig, 0, 0, 255);
imagejpeg($im, null, 100);
?>
In your case the code would look something like the following since you are working with a gif image.
Code:
<?php
header('Content-type: image/gif');
$filename = 'http://www.seangillen.com/Untitled-1.gif';
$im = imagecreatefromgif($filename);
imagetruecolortopalette($im, false, 255);
$ig = imagecolorat($im, 0, 0);
imagecolorset($im, $ig, 0, 99, 0);
imagegif($im, null, 100);
?>
Look at the other sample scripts too and let me know where you get stuck. I'll help if I can.
Bookmarks