Page 1 of 1

Converting CMYK JPEG's to RGB

Posted: 2011-05-29T14:54:22-07:00
by cchd
I have many JPEG's produced by pdf2html from a professional Quark-generated pdf source. The identify command says these are in the CMYK colorspace but do not have any profile.

I have tried converting them from CMYK to RGB using -colorspace RGB and also with -profile parameters and two different sets of downloaded profiles.

In all cases the resulting jpg seems identical (through Gwenview or a browser) to the original, though identify confirms that it has been processed.

To save space here I have posted the details on http://archives.felsted.org/pdfprob/

Can anyone save me from banging my head on this brick wall?

Re: Converting CMYK JPEG's to RGB

Posted: 2011-05-29T16:13:12-07:00
by fmw42
I believe that your image may be a negated (by your software?) CMYK. The following seems to work for me.

convert index-1_8.jpg -negate -profile Profiles/USWebCoatedSWOP.icc -profile Profiles/sRGB.icc index-1_8_neg_uswebswop_srgb.jpg

But I will defer to others more expert than I with CMYK images.

Re: Converting CMYK JPEG's to RGB

Posted: 2011-05-30T00:03:34-07:00
by cchd
You are FANTASTIC! Very many thanks. The '-negate' is the answer, and it works in all varieties of the commands I tried - whichever [sensible] color profiles I use, and even with the simple convert -negate -colorspace RGB index-1_8.jpg rgb6.jpg.

[The results from use of the different profile files are probably slightly different, but not to my untutored eye.]

But once again, many thanks, and I can now proceed with this project.

Re: Converting CMYK JPEG's to RGB

Posted: 2011-05-30T19:01:40-07:00
by anthony
RGB and CMY are just a -negate of the colorspace.
Note however the CMYK has the extra complication of a 'Black'.
Black = minimum of CMY, which is then subtracted for all channels. As such for any specific pixel one CMY channel value will be zero!