ImageGear for C and C++ on Windows v19.6 - Updated
IG_color_space_level_set
API Reference Guide > Core Component API Reference > Core Component Functions Reference > Color Space Options Functions > IG_color_space_level_set

This function has been deprecated and will be removed from the public API in a future release. Please use IG_image_colorspace_convert instead.

Declaration:

 
Copy Code
AT_ERRCOUNT ACCUAPI IG_color_space_level_set(
        AT_MODE nColorSpaceID, 
        AT_MODE nSupportLevel
);

Arguments:

Name Type Description
nColorSpaceID AT_MODE Set this to an AT_MODE constant for the type of color space you would like to set the support level setting for. For example: IG_COLOR_SPACE_CMYK.
nSupportLevel AT_MODE Set this to an AT_MODE constant for level of support for the color space specified in the first argument. For CMYK support, the possible settings are IG_CONVERT_TO_RGB or IG_FULL_SUPPORT.
ImageGear fully supports the loading and saving of CMYK images. A CMYK image will only be converted to RGB for the purpose of display. CMYK is a color scheme designed for printing and cannot be used for screen display. For more details see the section Converting Image Color Space in the Using ImageGear Chapter.

Return Value:

Returns the number of ImageGear errors that occurred during this function call. If there are no errors, the return value is IGE_SUCCESS.

Supported Raster Image Formats:

This function does not process image pixels.

Sample:

Color

Example:

 
Copy Code
AT_ERRCOUNT      nErrcount;
HIGEAR  hIGear;
nErrcount= IG_color_space_level_set(IG_COLOR_SPACE_CMYK, IG_COLOR_FULL_SUPPORT);

Remarks:

This function allows you to set the option level setting for the color space that you specify.

You must supply nColorSpaceID with a constant of type AT_MODE from accucnst.h that specifies the color space you wish to query, and nSupportLevel with a constant of type AT_MODE that specifies the level of support you would like your application to provide.

The CMYK color space is supported using the following settings:

IG_CONVERT_TO_RGB Loads a CMYK image and converts it to RGB.
IG_FULL_SUPPORT Full support for loading and saving CMYK images.