This function returns the bit depth of the channel specified by the Index parameter.
Copy Code
|
|
---|---|
AT_INT ACCUAPI IG_DIB_channel_depth_get( HIGDIBINFO hDIB, AT_INT Index ); |
Name | Type | Description |
---|---|---|
hDIB | HIGDIBINFO | DIB info handle. |
Index | AT_INT | Index of channel of which to return bit depth. |
Returns specified channel's bit depth.
All pixel formats supported by ImageGear for C and C++.
Copy Code
|
|
---|---|
AT_ERRCOUNT nErrcount; /* Number of errors on stack */ HIGDIBINFO hDIBInfo; /* DIB info handle */ HIGEAR hImage; /* HIGEAR handle of image */ AT_INT depth; /* Returned depth of first channel */ nErrcount = IG_image_DIB_info_get(hImage, &hDIBInfo); depth = IG_DIB_channel_depth_get(hDIBInfo, 0); |
For example, if you had a typical 24-bit RGB image with three 8-bit channels, you could specify 0, 1, or 2 for the index and the return value would be 8.