SeparateObjects creates a list (IERectList) of IERect rectangles. Each rectangle encloses a found objects.

This method works well to separate photos or simple objects over a white or black background. The background cannot contain a pattern.

Namespace: HiComponents.IEvolution
Assembly: IEvolution2 (in IEvolution2.dll) Version: 10.1.0.0

Syntax

         
 C#  Visual Basic  Visual C++ 
public IERectList SeparateObjects(
	int quality,
	bool mergeCommonAreas,
	IERGB backgroundColorBegin,
	IERGB backgroundColorEnd
)
Public Function SeparateObjects ( _
	quality As Integer, _
	mergeCommonAreas As Boolean, _
	backgroundColorBegin As IERGB, _
	backgroundColorEnd As IERGB _
) As IERectList
public:
IERectList^ SeparateObjects(
	int quality, 
	bool mergeCommonAreas, 
	IERGB backgroundColorBegin, 
	IERGB backgroundColorEnd
)

Parameters

quality
Int32
Specifies the contour search routine definition. Minimum value is 1, suggested is 4. Lower values increases speed, but could not recognize complex objects like characters.
mergeCommonAreas
Boolean
If mergeCommonAreas is true, when two rectangles intersects they are merged. When it is false, two rectangles are merged only if they are inclusive.
backgroundColorBegin
IERGB
Specifies the background begin color range. This helps the function to separate the background and the objects.
backgroundColorEnd
IERGB
Specifies the background end color range. This helps the function to separate the background and the objects.

Return Value

Returns a IERectList representing a list of found rectangles.

Examples

CopyC#
IERectList rects = ieViewer1.Image.SeparateObjects(4, true);
...
rects.Dispose();

See Also