[reportlab-users] Reportlab and CMYK Images

Robin Becker reportlab-users@reportlab.com
Tue, 30 Sep 2003 14:57:31 +0100


In article <3F797CE4.5040102@gmx.net>, Oliver Bleutgen <myzope@gmx.net>
writes
>Can somebody give me a short overview about how Reportlab handles CMYK 
>images? I had a look at the source, but I'm not sure I got it right.
>
>It seems if I use a PIL Image instance, the image is always converted to 
>RGB, while jpeg files are not converted.
>
>On a related note, it seems there's no implementation in reportlab for 
>adding other types of images, is that right?
>
>
>Thanks,
>oliver
>
.....

You're right at present we handle only rgb images via PIL. As I
understand it PIL can handle other kinds of things including CMYK and I
guess you are right to say that converting to RGB would be wrong for
those images.

At present I'm sure we aren't planning an immediate effort to add cmyk
images, but for JPEGS I see that we allow for the colorspace to default
to 'DeviceCMYK' after testing for 1 or 3 color components.

When loading from a bitmap type image I guess we ought to allow for
testing the number of image components & masking & etc etc etc sigh :(
-- 
Robin Becker