Jump to content

Prestashop Changes Colour Tone After Image Import


Recommended Posts

  • 2 months later...

With Prestools you can use the Imagick library for PHP that allows you to regenerate your images with a better quality.


Choose in its menu Tools & Stats -> Image Regenerate. When you have Imagick installed and active it will show you the choice between GD and Imagick. 


Imagick images really look much better.

Edited by musicmaster (see edit history)
Link to comment
Share on other sites

Actually the browsers have supported ICC profiles embedded in images the last few years.


But this is a really complex area. Some reading material for those wanting to learn more:




There were some patches floating around here some time back that changed the PrestaShop image handling from using GD2 to using ImageMagick.


The thing that has always really annoyed me with the PrestaShop image handling is that it doesn't keep the original image file uploaded unchanged someplace, making it impossible to regenerate things from the original after making changes to the image handling code.

Link to comment
Share on other sites

Your suggestion that pictures should be converted to something without a colour profile prior to upload is quite correct for user interface and web design elements. It's also true for any situation where you mix and match multiple images, especially when you mix it with web design elements like backgrounds and CSS colours.


It is however not true for photographs which should stand alone, which is the original posters point and my point. I could refer to lots of articles about this, but here's a recent and simple one: http://www.color-management-guide.com/web-browser-color-management.html


It's not cool when I have hired a fashion photographer to take beautiful pictures of the pink dress I'm selling, only to have it end up looking coral on many users webpage. I'm working on a new clothing webshop at the moment with lots of huge resolution fashion photography. This is an important issue to get right.


The main problem here is GD2, it's just to simplistic.


Maybe I should dig up those old patches that replace GD2 with ImageMagick in PrestaShop. Think it was this one:



And perhaps also come up with some patch that keeps the original uploaded image unchanged someplace in the file system, to make it easy to experiment with different ways to handle this problem.


If only the day had more than 24 hours...

Link to comment
Share on other sites

One nice thing about implementing ImageManager::resize() using ImageMagick is that it's also possible to add a configuration option that controls if meta-information is stripped or not. Then those who like PrestaShop as it is now (strip all exif/ICC etc metainfo) get their small images, and those of us with loads of professional photography images get to keep the ICC profiles etc.


The other thing that really annoys me with the ImageManager class is that it doesn't have a way to just store the original upload image, resize is called even for the upload, thereby losing forever the possibility to change algorithms or settings and try again to see how images look. Also the fact that all images shown on the website have been through two generations of resize cannot possibly be good for image quality.

Link to comment
Share on other sites

  • 1 year later...
On 5/24/2016 at 1:30 PM, mdekker said:

Managed to find a solution to the double compressing of product images.


I think that the module is finished. I added several extra options to get the most out of it as I really really like ImageMagick! It does a much better job at processing images.


You can find the module here: https://www.prestashop.com/forums/topic/530451-free-module-imagemagick-support-for-prestashop/


This link is broken. Can you fix this please?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...