Color Spaces
Image color matching uses color spaces to define the set of colors available
for a device. To each device context, the system assigns a default color space
whose attributes, such as color space type, gamut-matching method and color
endpoints, fully define how the system transforms color values for the device. You
can create your own color spaces and replace the default color space for a
device context by using the
CreateColorSpace and
SetColorSpace functions. These functions let you explicitly set the format of the color
values you use in your application and how the device interprets those values and
generates colors.
To create a color space, you set the members of a
LOGCOLORSPACE structure and pass the structure to the
CreateColorSpace function. You can either set the members to the values you want or specify
the filename of a color profile that contains the characterization of the device.
For more information, see
Color Profiles.
Every color space must have a color space type and a gamut matching method.
Gamut matching specifies whether colors in a given image are transformed into an
exact match or are modified to make best use of the gamut of the given device,
and is described in
Gamut Matching Method.
The color space types can be device
RGB (red, green, blue), device
CMYK (cyan, magenta, yellow, black), or calibrated RGB. Device RGB, the default
color space for device contexts, consists of the arbitrary set of colors for the
specified output device. Logical color values in this space are given as three
8-bit color values (in a 32-bit value) and are sent to the device driver
without transformation. Device CMYK is similar to device RGB except that logical
color values are given as four 8-bit values. You use this color space for devices,
typically printers, that use CMYK color values. For example, you might use it
to carry out color separation and pass color values directly to a CMYK printer.
Calibrated RGB consists of colors in the set defined by three color endpoints.
The color endpoints are given as three 32-bit values and are interpreted as
defined by the 1931 CIE (Commission Internationale de L'Eclairage) XYZ standard.
After you have created a color space, you can select it into a device context
by using the
SetColorSpace function. You can delete a color space if you no longer need it by using the
DeleteColorSpace function.
You can retrieve the color space for a specified device context by using the
GetColorSpace function. This is useful if you want to get the logical definition or color
profile file associated with the color space. You can use the
GetLogColorSpace function to copy this information to a
LOGCOLORSPACE structure.
- Software for developers
-
Delphi Components
.Net Components
Software for Android Developers
- More information resources
-
MegaDetailed.Net
Unix Manual Pages
Delphi Examples
- Databases for Amazon shops developers
-
Amazon Categories Database
Browse Nodes Database