Skip Menu |

This queue is for tickets about the Imager CPAN distribution.

Report information
The Basics
Id: 96204
Status: open
Priority: 30/
Queue: Imager

People
Owner: Nobody in particular
Requestors: JKRAMER [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: (no value)
Fixed in: (no value)



Subject: CMYK JPGs are converted to RGB, messing with colors
When I read a JPG with CMYK color space, it seems to be converted to RGB automatically when being written (regardless of the output format), leading to colors to be off. I can't find a way to change this behavior or set the color space to CMYK explicitly when writing. To reproduce, save the attached sample JPG and run: perl -MImager -e 'Imager->new(file => "orig.jpg")->write(file => "copy.jpg")'
Subject: orig.jpg
Download orig.jpg
image/jpeg 796.6k
orig.jpg
Subject: Re: [rt.cpan.org #96204] CMYK JPGs are converted to RGB, messing with colors
Date: Wed, 4 Jun 2014 19:30:04 +1000
To: Jonas Kramer via RT <bug-Imager [...] rt.cpan.org>
From: Tony Cook <tony [...] develop-help.com>
On Wed, Jun 04, 2014 at 04:37:16AM -0400, Jonas Kramer via RT wrote: Show quoted text
> When I read a JPG with CMYK color space, it seems to be converted to RGB automatically when being written (regardless of the output format), leading to colors to be off. I can't find a way to change this behavior or set the color space to CMYK explicitly when writing. > > To reproduce, save the attached sample JPG and run: > > perl -MImager -e 'Imager->new(file => "orig.jpg")->write(file => "copy.jpg")'
Hi Jonas, Unfortunately this isn't likely to change soon. Imager only supports RGB and greyscale images internally, so any images need to be converted to one of those colourspaces. Right now Imager uses a very primitive CMYK to RGB conversion, I plan to change that, but it requires a lot of pre-requisite work which won't be happening quickly. Tony