GetPS2ColorSpaceArray

[This is preliminary documentation and subject to change.]

The GetPS2ColorSpaceArray function retrieves the PostScript Level 2 color space array from a profile.

BOOL WINAPI GetPS2ColorSpaceArray(
  HPROFILE hProfile,
  DWORD dwIntent,
  DWORD dwCSAType,
  PBYTE pBuffer,
  PDWORD pcbSize,
  PBOOL pbBinary
);
 

Parameters

hProfile
Specifies a handle to the profile from which to retrieve the PostScript Level 2 color space array.
dwIntent
Specifies the desired rendering intent for the color space array. This field may take one of the following values:
INTENT_PERCEPTUAL
INTENT_SATURATION
INTENT_RELATIVE_COLORIMETRIC
INTENT_ABSOLUTE_COLORIMETRIC
 

For more information, see Rendering Intents.

dwCSAType
Specifies the type of color space array. Can take one of the following constant values:
Constant Meaning
CSA_A Get a CIEBasedA color space array from the monochrome profile.
CSA_GRAY Get a CIEBasedA color space array from the monochrome profile.
CSA_ABC Get a CIEBasedABC color space array from the RGB or L*a*b* profile.
CSA_DEF Get a CIEBasedDEF color space array from the RGB or L*a*b* profile.
CSA_RGB Get a CIEBasedDEF color space array followed by a CIEBasedABC color space array from the RGB profile. On execution, if the printer doesn't support CIEBasedDEF color spaces, the function uses the CIEBasedABC definition.
CSA_Lab Gets a CIEBasedABC color space array from the L*a*b* profile.
CSA_DEFG Get a CIEBasedDEFG color space array from the CMYK profile.
CSA_CMYK Get a CIEBasedCMYK color space array from the CMYK profile.

pBuffer
Pointer to a buffer in which the color space array is to be placed. If the pBuffer pointer is set to NULL, the function returns the required size of the buffer in the memory location pointed to by pcbSize.
pcbSize
Pointer to a variable containing the size of the buffer in bytes. On return, it contains the number of bytes copied into the buffer.
pbBinary
Pointer to a Boolean variable. If set to TRUE, the data copied could be binary. If set to FALSE, data should be encoded as ASCII85. On return, the memory location pointed to by pbBinary indicates whether the data returned actually is binary (TRUE) or ASCII85 (FALSE).

Return Values

If this function succeeds, the return value is TRUE. If this function succeeds, the return value is TRUE. It also returns TRUE if the pBuffer parameter is NULL and the size required for the buffer is copied into pcbSize.

If this function fails, the return value is FALSE. For extended error information, call GetLastError.

Remarks

If the color space array is not available in the profile, the GetPS2ColorSpaceArray function builds a PostScript Level 2 color space array using the profile contents. This array can then be used as the operand for the PostScript Level2 setcolorspace operator.

QuickInfo

  Windows NT: Requires version 5.0 or later.
  Windows: Requires Windows 98.
  Windows CE: Unsupported.
  Header: Declared in icm.h.
  Import Library: Use mscms.lib.

See Also

Color Management Overview, ICM 2.0 Functions