GIF Upload Creates Transparency

thisisted / 2012-03-14 15:57:08   

Hello,
Whenever I upload a GIF, Indexhibit chooses a color and makes it transparent.
Here's what I mean:

Original image

Image after uploading to Indexhibit

The exhibit in question (temporary link):
http://www.deborah-harris.com/beta-v1/prints/woodblock-prints/

The image was saved in the Save For Web panel of Photoshop, with transparency unchecked.
Is there a reason Indexhibit transparent's the image?

Thanks
Ted Levine
http://www.tedlev.com

Vaska A / 2012-03-14 16:03:27   

Yeah, because it sucks in that respect - it's been so long and you are the first person I can remember bringing this up. It's a bug.

The real solution is to simply not allow the GD library to try to do this - don't allow transparency on GIFs. Right now, it defaults to allow white to be transparent and for some reason it's catching more in that image.

As soon as I can, I want to make an Imagick version the photo processing tools but that will be a couple months at least.

Vaska A / 2012-03-14 16:14:55   

Lets see if this works - beginning on line 209 in /ndxz-studio/lib/media.php you will see this:

  1.             case 'gif':
  2.                 $this->checkBackground();
  3.                 $this->input_image = imagecreatefromgif($this->image);
  4.                 break;

Change it to this (comment out 'checkBackground'):

  1.             case 'gif':
  2.                 //$this->checkBackground();
  3.                 $this->input_image = imagecreatefromgif($this->image);
  4.                 break;
thisisted / 2012-03-14 16:16:32   
The real solution is to simply not allow the GD library to try to do this - don't allow transparency on GIFs

Is this possible to do in the current Indexhibit installation?
Where can I change this setting?

Thanks
Ted

thisisted / 2012-03-14 16:16:55   

Ah, good timing. I'll make the change now.

thisisted / 2012-03-14 16:21:11   

Fixed. Thanks Vaska!

Ted Levine
http://www.tedlev.com

This thread has been closed, thank you.