Join the web development community

How to compress the header grafic of a website without decreasing the quality

I want to optimize some pictures on my website. I have some very big header graphic which has also gradient effect. This graphic has more than 100KB. I would like to compress this header graphic but I do not know if this is possible without decreasing the quality of the graphic. I run a Drupal 7 website. Is there a module to do it? Can anybody assist me to solve the issue?

Junaed's picture

I doubt that you will get for compressing each images.

Vote the answer: 
0
No votes yet

You can find some modules to compress images on Drupal 7 here. Let me tell what is mentioned there in short. ImageAPI Optimize allows you to optimize any image when you are uploading it. But in your case, you need to optimize already uploaded images. You should use Max Image Size which will allow you to resize already uploaded according to your required. There is a slight problem you may face. It doesn't store the original image. If you want to resize and keep the original image, you may try Image Resize Filter. You can also use ImageMagick which comes as image toolkit on Drupal. Except these, Imagick module uses Imagick PHP extension.

 

Now about the quality-

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

In the two above mentioned places, you may set the JPEG quality of already uploaded images. The first one affects the other uploaded images. And the first one affects image field and image cache. You will find more about them here. A low image setting will provide you smaller size images with low quality and higher setting will do the opposite. You can try the quality ratio from 0 to 100% to get your desired result.

I hope this helps.