[gs-devel] Getting a JPX stream's colorspace

Igor V. Melichev igor.melichev at artifex.com
Thu Nov 29 11:57:54 PST 2007


Ralph,

> Igor, do you have any internal representations of colorspaces I could
> use for the C-level return?

The graphics library represents color space with gs_color_space_s structure.
But it is pretty complex and I'm not sure whether you need it.
Please explain :

1. What types of color spaces may be returned from .jpxgetcolorspace ?
Here is what the graphics library handles :
"DeviceGray", "DeviceRGB", "DeviceCMYK", "DevicePixel", "DeviceN",
"ICCBased", "CIEBasedDEFG", "CIEBasedDEF", "CIEBasedABC", "CIEBasedA",
"Separation", "Indexed"
(I dropped 'Pattern" because likely it's not a case for JPX).

2. What information about a specific color space to be retrieved with
.jpxgetcolorspace ?
For example, if it returns a CIEBased space, does it need to return
all parameters of CIEBased space ? (Maybe you need to
discuss with Alex for obtaining a right answer).

-------------------------------------

BTW, As I understand, the PDF interpreter code needs a color space
before running an image, but then it applies a JPX filter
to decode the image data. Can JPX library perform
a conversion to another color space as for ProcessColors?
If yes, then the image color space is processed
within the filter, and the PDF interpreter to be rewritten
so that it doesn't need the image color space
before running a JPX image.
This is just my guessing, which may be entirely wrong.

Igor.

----- Original Message ----- 
From: "Ralph Giles" <ralph.giles at artifex.com>
To: "Igor V. Melichev" <igor.melichev at artifex.com>
Cc: "Alex Cherepanov" <alexcher at quadnet.net>; <gs-devel at ghostscript.com>
Sent: Thursday, November 29, 2007 9:44 PM
Subject: Re: [gs-devel] Getting a JPX stream's colorspace


> On Thu, Nov 29, 2007 at 09:50:34AM +0300, Igor V. Melichev wrote:
>> >I guess I should provide a .jpxgetcolorspace operator
>>
>> Agree due to we want to move to C implementations.
>
> Yes. While writing a jpx parser in postscript would be fun, it's not the
> direction we want to go in.
>
> Igor, do you have any internal representations of colorspaces I could
> use for the C-level return?
>
> -r



More information about the gs-devel mailing list