[metapost] defaultcolormodel

Hans Hagen pragma at wxs.nl
Sat Jul 9 10:56:10 CEST 2011

On 9-7-2011 2:10, Reinhard Kotucha wrote:

> Not if black ink is ideal.  And brown shouldn't be CMYK(1,1,1,1), not
> even CMYK(1,1,1,0).  The latter might look brownish, but this is
> caused by non-ideal inks.  Nothing is perfect, but black ink is nearly
> perfect.  If in doubt, ask your chimney sweeper. :)

In print it matters how it's printed.

- clever printers can ignore colorants if black == 1
- is black printed last or a is nicely covering yellow overprinted
- printers can apply rasterization etc

too much going on there.

>   >  >  In LaTeX's color package, black is already CMYK(0,0,0,1), and this is
>   >  >  also a good choice for Metapost.  Please note that with CMYK(1,1,1,1)
>   >  >  you don't not only waste ink, the paper also gets too wet.
>   >
>   >  GRAY(0) is better, and also less code.
> Sure, but the question is what to do if no color is specified at all.
> In this case TeX and Metapost default to black and it matters how
> black is defined in CMYK color models when RGB is converted to CMYK.
> In RGB it's easy because all you have to do is to turn all lights off
> in order to get black.  In CMYK you have several choices, but given
> that black color pigments are ideal, there is only one reasonable
> choice.

It's not tex and mp defaulting .. it's the macro package and for 
instance in context we always had converters, reducers etc built in (in 
the case of mp also in the backend code).

In the past we could not define black in mp other than in rgb but gray 
was exported when r/g/b had equal values so (0,0,0) and (1,1,1) came out 
as gray as well.

As colors cannot be mixed (gray/rgb/cmyk are different datatypes in mp) 
we should not change the definition of black/white if only because users 
can have code like .5[red,black] that will fail then.


                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl

More information about the metapost mailing list