On Tue, Mar 24, 2009 at 9:54 AM, Michael van Tellingen <michaelvantellin...@gmail.com> wrote:
> I've just tested my application with the PIL 1.1.7 tip and latest alpha and > still have problems with the conversion from CMYK jpeg to RGB. > The test images mailed earlier on this mailinglist (black background with > the text 'RED') somehow become yellow on my system (python 2.5 / osx > leopard). Yeah, I completely messed this one up. One crucial change didn't make it into the library, and embarrasingly enough, I then went on to make the JPEG regression test look for the broken behaviour... Here's the missing patch: $ hg diff libImaging/JpegDecode.c diff -r f17d08c18ab3 libImaging/JpegDecode.c --- a/libImaging/JpegDecode.c Mon Mar 23 12:51:13 2009 +0100 +++ b/libImaging/JpegDecode.c Wed Mar 25 01:04:59 2009 +0100 @@ -189,7 +189,8 @@ context->cinfo.out_color_space = JCS_GRAYSCALE; else if (strcmp(context->rawmode, "RGB") == 0) context->cinfo.out_color_space = JCS_RGB; - else if (strcmp(context->rawmode, "CMYK") == 0) + else if (strcmp(context->rawmode, "CMYK") == 0 || + strcmp(context->rawmode, "CMYK;I") == 0) context->cinfo.out_color_space = JCS_CMYK; else if (strcmp(context->rawmode, "YCbCr") == 0) context->cinfo.out_color_space = JCS_YCbCr; Thanks /F _______________________________________________ Image-SIG maillist - Image-SIG@python.org http://mail.python.org/mailman/listinfo/image-sig