[cairo] Spot colors (and CMYK)

James Cloos cloos at jhcloos.com
Fri Jan 15 06:33:20 PST 2010


>>>>> "Bill" == Bill Spitzak <spitzak at gmail.com> writes:

>> for cairo_t meaning one of DeviceRGB, sRGB or scRGB -- which one whould
>> need to decided and documented.

Bill> In floating point sRGB and scRGB are identical. scRGB is just a larger
Bill> than 0-1 range which floating point supports anyway.

Correct.  If the goal is to use floats internally then there is no need
to differentiate between the latter two.  I don't know, though, whether
using floats is the goal of the primary devs, and it is still possible
that it is better to define the default as "DeviceRGB" with no specific
colour space defined?

Bill> You may be thinking of "linear" light levels rather than the gamma
Bill> corrected levels sRGB define. In linear space adding two colors
Bill> numerically is the same as adding two lights physically. I am not sure
Bill> what to call this but scRGB is the wrong term. I use "linearRGB" but
Bill> an awful lot of code uses the term "linear" for what you are calling
Bill> Device space (in that the transformation to the device is the linear
Bill> identity), this has led to a lot of confusion.

That is true; and indeed I did not consider what you are describing as
linear space yesterday when I wrote that email.

Bill> In more cases than you might think the other data can be zero. All
Bill> 3-D spaces with a transformation to CIEXYZ can be transformed to
Bill> non-clamped sRGB, the inverse transformation of the sRGBA values
Bill> can be used to recover the values.

Indeed.  Note, though, that ink spaces do not have a one-to-one and onto
relationship with XYZ, and so it is still necessary for every object to
specify its colour space.  Most of the time they can be translated into
a floating point RGB space, but their are exceptions.  And given that
apps like inkscape and libs lib poppler want to use cairo for generating
PDF for print, cairo needs to be able to meet the expectations of users
who are generating, editing, proofing, etc art for print.

Bill> For spot colors the spot color is recovered by looking up the sRGB
Bill> color. This assumes a 1:1 mapping between spot color and sRGB.
Bill> Another channel is used to transfer this information.

That 1:1 mapping does not always exist.  The fallback does need to be
specified, but sometimes it is used just as a hint for where the spot
will print, such as when the spot is a varnish or the like.

Your suggestion for cairo_color_t is reasonable, but cairo still needs
a cairo_color_space_t, too.

-JimC
-- 
James Cloos <cloos at jhcloos.com>         OpenPGP: 1024D/ED7DAEA6


More information about the cairo mailing list