Is there an way to configure the thumb() function for keeping the copyright-informations & the color-profiles?
Thanks in advance
Is there an way to configure the thumb() function for keeping the copyright-informations & the color-profiles?
Thanks in advance
Solved. I wrote my own thumb driver.
May you share, what library you have used for that purpose or how you solved this?
Would be very interesting, because I also work on an advanced thumbnail generator for kirby with a strong focus on responsive design and the picture element. Keeping color profiles could be an interesting addition to my plugin.
Hi Fabian,
remove the »-strip« command to include color profiles.
I just want to add something…
I use $command[] = ‘-thumbnail’;
instead of -resize (line 291 in thump.php) and -strip (line 277).
-thumbnail keeps the color profiles and delete everything else
-strip deletes everything… color profiles, IPTC profiles, EXIF, comments
Thank you for this but I still have a problem.
Removing the line -strip
helps to keep the right colors but changing -resize
to -thumbnail
breaks the code and all the thumbnails are generated as the original file in HD.
You mean that the images are not resized?
Could you please put this line at the end of your thumb driver and post the output here:
var_dump(implode(' ', $command));
What would also help is the output of convert --version
on the command line.
BTW… which IM version do you use?
Because before IM v6.5.4-7 the “-thumbnail” command would strip ALL profiles from the image, including the ICC color profiles. From this version onward the color profiles will be preserved.
The best option I found to keep at best the colors of the images when resizing it is the following :
I created an issue for this problem that color profiles are removed from thumbs.
This is great, thank you.