Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Preserve ICC profile while stripping extra metadata #1

Merged
merged 1 commit into from
Jun 24, 2019

Conversation

CGillen
Copy link

@CGillen CGillen commented Apr 23, 2019

During the tiling process, ICC profiles are being stripped out while using GD and PHP Imagick. This can cause washed out colors on the tiled images compared to the original and other static derivatives. The command line version of ImageMagick is un-affected by this issue, but is slow and resource intensive.

As far as my research has gone GD doesn't offer a solution for this, however PHP Imagick has a solution documented here: https://www.php.net/manual/en/imagick.stripimage.php#120380

This PR is an implementation of that solution and resolves the problem for Imagick, which is a step in the right direction.

@Daniel-KM
Copy link
Owner

Hi,
Thanks for your commit, I merged it and integrated it in last version of IiifServer/Universal Viewer (for Omeka). In fact, it depends on the version of imagick, because I don't have this issue. nevertheless, it seems that it may be useful in some cases.

For gd, this is a libgd issue (#libgd/libgd/issues/136). It can be fixed with a simple copy of the exif metadata from source to tiles with https://github.com/slavicv/jpeg-icc or https://github.com/pel/pel. I Included it in the module.

Sincerely,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants