Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

Previous Book Contents Book Index Next

Inside Macintosh: Imaging With QuickDraw /
Chapter 4 - Color QuickDraw / Color QuickDraw Reference
Data Structures /


RGBColor

You usually specify a color to Color QuickDraw by creating an RGBColor record in which you assign the red, green, and blue values of the color. For example, when you want to set the foreground color for drawing, you create an RGBColor record that defines the foreground color you desire; then you pass that record as a parameter to the RGBForeColor procedure.

In an RGBColor record, three 16-bit unsigned integers give the intensity values for the three additive primary colors.

TYPE RGBColor\xDD= 
RECORD
   red:\xDD    Integer;    {red\xDDcomponent}
   green:   Integer;    {green\xDDcomponent}
   blue:    Integer;    {blue\xDDcomponent}
END;
Field Description
red
An unsigned integer specifying the red value of the color.
green
An unsigned integer specifying the green value of the color.
blue
An unsigned integer specifying the blue value of the color.

Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996