I am attempting to devise the proper commandline for resizing an image with color profile for upload to Tumblr, which allows color profiles but does not understand them. Fullsize profiled images look fine if untouched (fitting within resolution/size constraints) but thumbnails look bad. I can do this with Photoshop, but cannot find a way to reproduce it with ImageMagick.
Example image: https://40.media.tumblr.com/5ee6c33a4ed ... 1_1280.png
Thumbnail: https://40.media.tumblr.com/5ee6c33a4ed ... o1_540.png
This is a PNG I saw and noticed issue on, with ICC profile. Note how Tumblr's resize system has damaged colors. (I am testing in FF/Chrome/IE10 on color-profiled monitor)
If I try to scale using my current commandline:
Code: Select all
magick input.png -colorspace RGB -filter Lanczos -define filter:blur=.9891028367558475 -distort Resize 714x1009 -colorspace sRGB scaled.png
(size param is width-1 to make color change obvious, not resolution; other options are taken from Robidoux's recommendations)
I have tried some combinations of -profile option but none of them result in quality as high as Photoshop.
Opening in Photoshop and using Save For Web, resizing to 714x1009, choosing "Embed color profile" and "Convert to sRGB" results in a thumbnail that looks much better (not perfect) and an accurate fullsized image.
Is there any way I can reproduce this with ImageMagick or improve on it?
I have a semi-automated system for processing/upload and this issue prevents it from properly running without human supervision.