Improving Imagecache JPG quality

Events happening in the community are now at Drupal community events on www.drupal.org.
gonz's picture

I really don't like posting support questions here in the groups section, but you guys are awesome and I wanted to ask you first.

I am having consistent issues with Image Quality from thumbnail images generated by Imagecache.

I use a CCK Image field to upload the image - then I run image cache on it to create the teaser and full view.

The quality for the large image is usually fine - but the thumbnail is really not up to par.

Is there a way to control that - using PHP settings for GD library?

I don't really have access to root on all my sites, but have you ever used ImageMagic Tool kit? Does this help?

Here is one of many examples that has the poor quality Jpeg on thumbnails.

http://www.facetofacetour.com/news

(I am attaching a screenshot of my imagecache settings for this Square Thumbnail)

Any thoughts would be awesome.

Thanks PDXers

AttachmentSize
Picture 24.png79.55 KB

Comments

try imagemagick?

drewish's picture

if it's installed on your server i'd suggest giving imagemagick a try.

Image Advanced

christefano's picture

Even though you're using Imagecache, you can get better images by installing the Image Advanced module (which comes with the Image module).

Looks like thats an Image Magic Addition huh

gonz's picture

Looks like thats an Image Magic Addition as well - the problem is Image Magic has to be installed by shell to be compiled and I dont have access to shell very often when working for clients on shared hosting services, but thanks for the insight.

I kinda figured it would take Image Magick to improve the quality, I just wish it was something easier that I have access to.

By default Drupal resamples

matt westgate's picture

By default Drupal resamples uploaded jpgs to 75% of their original quality. This could very well be what your running into. Try tweaking the settings here: example.com/admin/settings/image-toolkit

I cant believe how many

gonz's picture

I cant believe how many times I have seen that link and it never registered to me - thanks for the extra set of eyes - I am pretty sure this is exactly what I was looking for.

Thanks.

I ended up changing that

citronica's picture

I ended up changing that setting in two places -- not sure what the difference is:

  • /admin/settings/image-toolkit
  • /admin/settings/imageapi/config

This is a very useful

CHEETAH's picture

This is a very useful suggestion..
there seems to be 3 separate 'settings' forms for this particular setting..
one for Imagemagick and it seems that there are two for GD2 Imagetoolkit

What is the difference

mrfelton's picture

What is the difference between the two settings:

/admin/settings/imageapi/config
/admin/settings/image-toolkit

--
Tom
www.systemseed.com - drupal development. drupal training. drupal support.

The first one is for

grendzy's picture

The first one is for imageapi. Primarily, this means imagecache presets.

The second one is for core's image.inc. This is used for resizing profile pictures in core, and some contrib modules (though I can't think of any offhand).

By default Drupal resamples

matt westgate's picture

By default Drupal resamples uploaded jpgs to 75% of their original quality. This could very well be what your running into. Try tweaking the settings here: example.com/admin/settings/image-toolkit

I actually asked a related

mrfelton's picture

I actually asked a related question over at groups.drupal.org/image . But, since this post clearly has more visibility, and it is on a very similar topic I thought I'd spam you all with a link to it! Sorry. If anybody can answer my second question on that post relating to image quality, I would greatly appreciate it (my first question has been answered on this thread already).

--
Tom
www.systemseed.com - drupal development. drupal training. drupal support.

no eye catching change

shima's picture

hi every body
in this pages:
/admin/settings/imageapi/config
/admin/settings/image-toolkit
i increased value to 100% but there is no eye catching change :(
outside of images are not soft
i just use view and image cache to display some images as gallery
is there another way to fix it?

Hello, have you found a solution ?

MakeOnlineShop's picture

Hello, have you found a solution ?

Thanks a lot.

Quality problem

averyprog's picture

I was having the same problem. Changing all 3 of these setting fixed it. Perhaps having all of these settings changing the same things, it could be taking 75% of 75... or 56%?

I had to flush each of the image presets in the imagecache UI before it made a difference.

Thanks

baff's picture

Thank you for your thoughts. Changing from 75 to 100% and flushing caches helped

No improvement with 100% image quality

MakeOnlineShop's picture

Hello,

I have tried to set all to 100% quality:

admin/settings/image-toolkit
admin/settings/imageapi/config
admin/settings/imageapi/config/imageapi_imagemagick

But the quality hasn't improved (I flushed).

Any help ?

Thanks a lot.

public://styles/ directory

mile23's picture

When your site applies a style to an image, it stores the generated file under [public files]/styles/[style name]. If you delete that directory, Drupal will regenerate them. Just flushing the cache won't do this.

So therefore: Delete it.

Obviously, you want to make backups, etc.

I cannot find this folder

MakeOnlineShop's picture

Thank you, but I cannot find this folder ?

Also, when I change some IMAGECACHE settings (like adding a watermark), I do not need to delete any folder, I just flush and then pictures show with the new watermark, so can you explain me why I should delete files to see any improvement after setting pictures quality to 100% ?

Thanks again.

Unless I'm mistaken, the 100%

mile23's picture

Unless I'm mistaken, the 100% setting applies to future images.

The folder will be on the server, usually at /sites/default/files/styles, but of course you can change the public directory so it might be somewhere else.

Portland (Oregon)

Group notifications

This group offers an RSS feed. Or subscribe to these personalized, sitewide feeds:

Hot content this week