ConvertDIBColorSpace

#include "BIImage.H"

 

HDIB CALLBACK ConvertDIBColorSpace( HDIB   HDib,
int         nFormtSrc,
int         nFormatDest,
int         iShowProgress,
HWND hParent)

Description

This function will convert the color of pixels of the input DIB. The input DIB must be 24 bit per pixel except for CMYK color space. If the nFormatSrc is CMYK, the input DIB must be 32 bit per pixel. If the nFormtDest is CMYK, the output DIB will be 32 bit per pixel.

Parameters

HDIB

hDIB

Handle of the DIB to filter.

int

nFormatSrc

Color space format of the input DIB. If this parameter is not valid, the function returns NULL.

Int

nFormatDest

Color space format of the output DIB. If this parameter is not valid, the function returns NULL.

int

iShowProgress

This parameter specifies the displaying of the progressbar.

HWND

hParent

Handler of the parent window. If the iShowProgress parameter is FALSE, this parameter will be ignored.

Return values

The handle of the new converted DIB or NULL if an error occurred. If any error occurs the GetLastColorConvertError function will be retrieves the error code.

Programming notes

The function will not free the input DIB.

Requirements

Header :     Declared in BIImage.h; include BIImage.h.

Library :    Use BIImage.lib.

DLLs :       BIimage.dll.