[metapost] defaultcolormodel
luigi scarso
luigi.scarso at gmail.com
Fri Jul 8 17:03:59 CEST 2011
On Fri, Jul 8, 2011 at 4:32 PM, Stephan Hennig <mailing_list at arcor.de> wrote:
> schrieb luigi scarso:
>> On Fri, Jul 8, 2011 at 12:31 PM, Stephan Hennig <mailing_list at arcor.de> wrote:
>> yes, of course. Probably in the default format, or in metapost itself
>> there is a default color (0,0,0)
>
> In the engine, AFAIK. And there are (0,0,0,1) for the CMYK model and 0
> for the grey scale model, too.
>
>
>>> Think about MetaFont that
>>> has no notion of colours, yet it has to distinguish between pixels that
>>> have been touched by a pen and those that haven't in the output. This
>>> 'implicit' black is what defaultcolormodel refers to (and what I meant
>>> by 'black ink').
>> Almost.
>> In Metafont each pixel has 7 weights: -3,-2,-1,0,1,2,3, hence
>> it's a kind of gray color space.
>
> Thanks for pointing this out. I'm not a regular MetaFont user, but I do
> know that MetaFont doesn't have a 'withcolor' primitive.
I believe that one can program a (useless?) macro
"withcolor " where every (rgb,cmyk,gray) color goes to {-3,-2,...3}
but I believe that this informations is lost in th gf file
>Do I figure
> correctly, that the weights indicate to what extend the area of a pixel
> has been covered by the pen?
Yes. This can happen if one draw a gliph like, for example, '*' ,
where in the middle of the cross
the pixels probably have weight 3, but also in some critical paths .
For example, if one pickup a circular pen with diameter d and draw a
path (x,y) where
y=ax^2
there are some combinations of 'd' and 'a' where some pixels around
the origin / y-axis have 2 or 3 or even more weight.
--
luigi
More information about the metapost
mailing list