AutoSegment method (LEADMrc Control)
Builder Syntax |
int AutoSegment(TLEADImage* LEADImg, int nMinWidth, int nMinHeight); |
Delphi Syntax |
Function AutoSegment(LEADImg: TLEADImage; nMinWidth: L_INT; nMinHeight: L_INT): L_INT; |
Overview |
Refer to Working with the LEADMrc Control. |
Remarks
(Document/Medical only) Automatically segments the given LEADImage's bitmap.
Call this method to segment the bitmap automatically. LEADTOOLS segments the bitmap into blocks nMinWidth wide by nMinHeight long. Segments are assigned a type according to the number of colors they have (those with a few colors become text segments and those with many colors become picture segments). Segments with the same type are combined.
Call the StartSegmentation method before using any of the segmentation methods. When the LEADMrc object is no longer needed, free it by calling the StopSegmentation method.
Set the following properties before calling the AutoSegment method to control the segmentation process:
If the AutoSegment method is called with the ImageType property set to IMAGETYPE_SCANNED (the default value), noise is removed from the image before segmenting it. Set the ImageType property to IMAGETYPE_COMPUTERGENERATED if noise does not need to be removed from the image.
The following properties are used solely by the AutoSegment method:
Sensitivity property
ImageType property
See Also