[cairo] Spot colors (and CMYK)
spitzak at gmail.com
Fri Feb 12 14:59:07 PST 2010
Any name should help in determining what gamma curve is applied to the
values outside the 0-1 range.
We certainly want to match the Microsoft scRGB spec, which continues the
sRGB function for values greater than one, and uses -f(-x) for values
less than 1 (where f is the positive function). There are other
possibilities such as continuing the linear sRGB line for negative
values, and using a straight tangent line for values greater than 1,
these should be rejected as they have no major advantages and will not
match scRGB which may become popular.
Therefore using "scRGB" as the name may give a hint as to what is being
done. Unfortunatly scRGB also defines an offset and scaling value so
that the approximate -.5 to 7.5 range can be stored in an integer, which
we do NOT want. scRGB also defines a linear as well as gamma mapping. I
would think it would be obvious we are not doing any of these
My favorite is to just call this "sRGB". Nobody seems to complain that
the values are in fact 1/255 the values often used to describe an "sRGB"
image, because the fact that the parameters are double makes the
obvious. In the same way I think the double parameters make the
unclamped nature obvious. A quick note on how to linearlize the range is
all that is needed.
Another alternative is "unclamped sRGB" or "floating point sRGB", or
"floating point scRGB".
Any name like "CairoRGB" would imply the primaries are different than
sRGB and therefore I do not think should be used.
Carl Worth wrote:
> On Thu, 21 Jan 2010 10:06:11 -0500, Chris Murphy <lists at colorremedies.com> wrote:
>> I suggest remedying this quickly. Call it CairoRGB v1.0, or CairoRGB
>> for short if you want. Anything but relating it to either sRGB or
> The only really fixed naming that we have here is as follows:
> cairo_set_source_rgb (cairo_t *cr, double red, double green, double blue);
> We've always intended that to have the same primaries and curves as
> sRGB, but obviously this isn't an 8-bit-per-channel specification of
> color. And we've always had a plan to document this as accepting values
> outside the range of [0.0, 1.0] in order to support a wide gamut.
> So we've had that notion for a long time, and I'd love a good name for
> it. Something like "wide-gamut floating-point sRGB" seems like the most
> descriptive and accurate, (where something like CairoRGB would not be
> descriptive at all about the primary/curves compatibility with sRGB).
> So that's how colors currently enter cairo (as a floating-point R,G,B
> triple). And as we talk about adding spot colors (with a named
> identifier along with some "alternate" color representation), I need to
> see a convincing argument that the alternate shouldn't be the same,
> floating-point RGB triple of cairo_set_source_rgb.
More information about the cairo