Closed (fixed)
Project:
ImageField
Version:
6.x-3.0-rc1
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
20 Mar 2009 at 15:22 UTC
Updated:
28 Apr 2009 at 01:30 UTC
Jump to comment: Most recent file
Comments
Comment #1
quicksketchDoes this problem only exist with the attached image? What are your max and min size set to?
Comment #2
joachim commentedNope, my designer reports the same error with another, similar image.
I set max and min to 210x210 to force this exact size image.
Comment #3
quicksketchThe function in image.gd.inc that calls imagecolorsforindex() is image_gd_resize(), which had me worried that your image was being resized for some reason, despite being exactly the same size as the required dimensions.
Turns out the required size check is just fine, it's the creation of the thumbnail that's causing this error. Since Drupal core can't resize animated GIFs properly, our only option might be to check if ImageAPI is available and use it for resizing if available. Though I'm not sure it can resize animated GIFs either.
Comment #4
quicksketchWell a simple solution to this is to simply suppress the errors. The image generation is still successful if image_resize() returns TRUE (which it seems to), and I've added separate messages if the resizing fails completely.