Closed (fixed)
Project:
ImageCache
Version:
6.x-2.0-beta10
Component:
Miscellaneous
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
12 Nov 2010 at 08:58 UTC
Updated:
2 Jun 2012 at 22:36 UTC
I just noticed that I have an image that is already 460px wide and I print it out through preset that only has "scale: width 460" action on it, the image gets compressed again - not just copied - thus reducing the initial quality.
Original image:
http://satumaa.yle.fi/sites/satumaa.yle.fi/files/images/suvi-ja-marko-bl...
Same image through imagecache preset:
http://satumaa.yle.fi/sites/satumaa.yle.fi/files/imagecache/6col/images/...
Is there a way to avoid this unnecessary action? IE. if there image is already in right size, just copy the original to a new path?
Comments
Comment #1
tormu commentedThis is how we handled it. When the image is displayed, we check if the preset only has one action and if it's scale. If that's true, then the image size is compared to the scale settings to see if there's a need for a scale or not. If not, then the original image is used.
And yeah, that code isn't as elegant as I'd hope for it to be, but at least it seems working. I hope this feature gets into the module in some way, though I think it would be better to stick it into the preset setting page..
Comment #2
fizk commentedPlease reopen if this is still an issue with ImageCache 6.x-2.0-rc1.