CMYK to sRGB - Has something changed?

The MagickWand interface is a new high-level C API interface to ImageMagick core methods. We discourage the use of the core methods and encourage the use of this API instead. Post MagickWand questions, bug reports, and suggestions to this forum.
Post Reply
dirving
Posts: 13
Joined: 2008-08-28T13:45:14-07:00

CMYK to sRGB - Has something changed?

Post by dirving »

Hi everyone,

This is probably a dumb question but bear with me... I'm upgrading some C software I wrote in which I make use of MagickWand. The version I'm upgrading from is 6.4.7 and I'm going to 7.0.7-11. Everything is going fine with the exception of colorspace conversion.

In my code that I use in 6.4.7, the process I use to convert from a CMYK colorspace to sRGB has always been:

1. Check if the CMYK image has an embedded ICC profile. If it doesn't, add USWebCoatedSWOP.icc using MagickSetImageProfile after reading in the ICC profile using FileToBlob.

2. Add the sRGB.icc profile using MagickProfileImage, again after reading it in using FileToBlob.

3. Finally, set the colorspace to sRGB using MagickSetImageColorspace.

This has always worked fine for me.. Now that I've upgraded to ImageMagick 7, the image that is generated, while in the sRGB colorspace, has inverted colors. The embedded profile I see in it (which I guess I would expect to be sRGB) is the USWebCoastedSWOP profile. On my test image, I ran "convert -profile sRGB.icc test.psd test.jpg" and everything converted just fine so I'm sure it's something I'm either doing wrong for Version 7 or that I've always been doing wrong and IM has been nice enough to ignore my stupidity.

Any thoughts on my process would be much appreciated!

Thanks,
Dave
dirving
Posts: 13
Joined: 2008-08-28T13:45:14-07:00

Re: CMYK to sRGB - Has something changed?

Post by dirving »

Nevermind... LCMS wasn't installed on the test server. Like I said, stupid ;)
Post Reply