| Previous | Table of Contents | Next |
Printers typically use cyan, magenta, and yellow colorants for subtractive coloring operations, hence this models name CMY. Like the RGB model, the CMY model can be viewed as a three-dimensional cube, using three Cartesian axes. Individual coordinate values range from, and include, 0.0 to 1.0representing how much colorant to deposit on presumably white surfaces. Since this model is subtractive, the origin (0.0, 0.0, 0.0) corresponds to a white value (i.e., paper with no colorant) and the (1.0, 1.0, 1.0) point corresponds to maximum allowed colorant application (Figure 13-2). As Chapter 8 discussed, this point should appear black, but colorant color shifts often render it something else. The same is true for most achromatic values and is a significant problem because the eye is extremely sensitive to color shifts that corrupt achromatic light, producing unbalanced grays.
Figure 13-2 The CMY model
The RGB model and the CMY model are theoretically related. A CMY model point corresponds to a known RGB model point using the following formulas:
Conversely, an RGB model point corresponds to a known CMY model point using the following formulas:
However, following these formulas usually produces a printing disaster. So, Hewlett-Packard thoughtfully provides gray balance documentation in its Hewlett-Packard DeskJet Printer Family Software Developers Guide. This guidance describes a gray balancing technique that compensates for noticeable unwanted absorption when using Hewlett-Packard DeskJet color ink jet printers. The method consists of first determining how close to an achromatic value a point is by computing the difference between the maximum and minimum CMY value and dividing the difference by the maximum value. If fully saturated, the quotients value is 1.0 point and the point is left alone. If it is achromatic, the quotient is 0.0 and the cyan value is reduced by one-third. In between, the cyan value is proportionally reduced depending on how close to an achromatic value the point is. The sample program PRINTPCX.C has the following programming:
int GrayBalanceCmyTriad(USGI *CyanPtr, USGI *MagentaPtr, USGI *YellowPtr)
{
USGI CyanValue, MagentaValue, YellowValue, Range;
USGI MaxPrimaryValue, MinPrimaryValue, MaxMinDelta;
CyanValue = *CyanPtr;
MagentaValue = *MagentaPtr;
YellowValue = *YellowPtr;
MaxPrimaryValue = (CyanValue > MagentaValue) ?
CyanValue : MagentaValue;
MaxPrimaryValue = (YellowValue > MaxPrimaryValue) ?
YellowValue : MaxPrimaryValue;
MinPrimaryValue = (CyanValue < MagentaValue) ?
CyanValue : MagentaValue;
MinPrimaryValue = (YellowValue < MinPrimaryValue) ?
YellowValue: MinPrimaryValue;
if (MaxPrimaryValue == 0)
*CyanPtr = 0;
else
{
Range = MaxPrimaryValue - MinPrimaryValue;
*CyanPtr = (int)
((long)CyanValue * ((long)Range + (2L * (long) MaxPrimaryValue))
/
(long) (MaxPrimaryValue * 3));
}
*MagentaPtr = MagentaValue;
*YellowPtr = YellowValue;
return 0;
}
While specific corrections necessary to address color shift vary from printer manufacturer to manufacturer, this code provides an example of one type of correction needed for color separations. There are many more beyond the scope of this book.
There is really no substitute for black inks ability to plunge image areas into darkness. So, the CMYK model, while related to the CMY model, additionally uses black ink to produce genuine achromatic tints, shades, and tones. In the acronym CMYK, K stands for Key. In this model K equals the minimum CMY model value. So:
This produces an under color removal operation that replaces a fraction of a points three C, M, Y coloration with a single black ink separation. However, Hewlett-Packard DeskJet CMY color inks and its black ink have different formulations. One is oil based and the other is water based. So, PRINTPCX.C reduces the inks natural oil-on-water dispersion effect by assigning a portion of the K value to the black ink, leaving the remaining darkening job to a gray balanced CMY combination. Welcome to the world of color printing and its typical considerations.
| Previous | Table of Contents | Next |