L_HolesRemovalBitmapRgn
#include "l_bitmap.h"
L_INT EXT_FUNCTION L_HolesRemovalBitmapRgn(pBitmap)
pBITMAPHANDLE pBitmap; |
/* pointer to the bitmap handle */ |
Removes all the holes in a region. This function is available in the Document/Medical Toolkits.
Parameter |
Description |
pBitmap |
Pointer to the bitmap handle referencing the bitmap to be changed. |
Returns
SUCCESS |
The function was successful. |
< 1 |
An error occurred. Refer to Return Codes. |
Comments
This function is designed to work on bitmaps that have a region. It removes the holes from the bitmap’s region. If this function is used with a bitmap that does not have a region, the "Invalid Parameter" error is returned.
To update a status bar or detect a user interrupt during execution of this function, refer to L_SetStatusCallback.
This function supports 12 and 16-bit grayscale and 48 and 64-bit color images. Support for 12 and 16-bit grayscale and 48 and 64-bit color images is available only in the Document/Medical toolkits.
This function supports signed data images.
Required DLLs and Libraries
LTIMG For a listing of the exact DLLs and Libraries needed, based on the toolkit version, refer to Files To Be Included With Your Application. |
Platforms
Windows 95 / 98 / Me, Windows 2000 / XP.
See Also
Example
/* This example loads a bitmap, defines a region on it, and applies the holes removal filter */
BITMAPHANDLE LeadBitmap;
/* Load the bitmap, keeping the bits per pixel of the file */
L_LoadBitmap (TEXT("IMAGE1.CMP"), &LeadBitmap, sizeof(BITMAPHANDLE), 0, ORDER_BGR, NULL, NULL);
/*put the predefined region*/
L_SetBitmapRgnHandle(&LeadBitmap,NULL, hRgn, L_RGN_SET);
/*Remove holes*/
L_HolesRemovalBitmapRgn (&LeadBitmap);