[pgf-tikz] RGB colour model for plain TeX users
Taylor, P
P.Taylor at rhul.ac.uk
Sat Nov 16 20:46:32 CET 2019
Jim Diamond wrote:
> [A] couple of minutes of playing
> around gave me
>
> \def\pgfutil at emu@cmyk#1#2,#3,#4,#5\@nil
> {
> \pgfmathsetmacro{\@red@}{(1 - #2) * (1 - #5)}%
> \pgfmathsetmacro{\@green@}{(1 - #3) * (1 - #5)}%
> \pgfmathsetmacro{\@blue@}{(1 - #4) * (1 - #5)}%
> \expandafter\edef\csname\string\color@#1\endcsname
> {\noexpand\xcolor@ {}{}{rgb}{\@red@,\@green@,\@blue@}}
> }
>
> I realize that converting cmyk to rgb is a lot more contentious than
> converting RGB to rgb,
I think that it is more than "contentious"; I think that it is genuinely
dangerous. I don't know whether PGF supports CMYK — if it does, then
wonderful. But if it does not, and if the addition of \pgfutil at emu@cmyk
were to suggest that it does, then that could lead users to believe that
they are generating CMYK graphics when they are in fact generating RGB.
Philip Taylor
More information about the pgf-tikz
mailing list