Page 1 of 1
How do I preserve the color of this white png in composite?
Posted: 2013-07-24T18:22:25-07:00
by builtbylane
Why is this happening? Is this a bug? how can I keep my transparent white.png white?
white.png :
http://cl.ly/image/1Q1U2A461g2V
background.jpg :
http://f.cl.ly/items/08173P2o0g3F3M2930 ... ground.jpg
Code: Select all
composite -gravity center -resize "10000x416>" white.png background.jpg dark.jpg
I want a white watermark, but I'm getting a dark one. produces :
http://cl.ly/image/3U2F1r1L3D3m
Version: ImageMagick 6.8.6-3 2013-07-06 Q16
Re: How do I preserve the color of this white png in composi
Posted: 2013-07-24T18:33:31-07:00
by fmw42
Your background JPG is CMYK (U.S. Web Coated Swop) and IM cannot composite unless both are sRGB. You need to use an sRGB.icc profile to convert the background first.
convert \( background.jpg -profile
/Users/fred/images/profiles/sRGB.icc \) white.png -flatten result.jpg
replace the blue path with your path to your sRGB.icc profile.
see
http://www.imagemagick.org/Usage/formats/#profiles
Re: How do I preserve the color of this white png in composi
Posted: 2013-07-25T11:52:29-07:00
by builtbylane
Thank you thank you! You have really helped me.
I have a followup question... is there a way with imagemagick to test the color profile before applying a conversion?
Re: How do I preserve the color of this white png in composi
Posted: 2013-07-25T13:06:47-07:00
by fmw42
use
identify -verbose yourimage
That will list out all the information. The colorspace should say CMYK or sRGB. Or at the bottom, you can see the exact profiles included with the file.