http://www.emgu.com
The grab cut algorithm for segmentation

Namespace: Emgu.CV
Assembly: Emgu.CV (in Emgu.CV.dll) Version: 2.3.0.1416 (2.3.0.1416)

Syntax

C#
public static void CvGrabCut(
	IntPtr img,
	IntPtr mask,
	ref Rectangle rect,
	IntPtr bgdModel,
	IntPtr fgdModel,
	int iterCount,
	GRABCUT_INIT_TYPE type
)
Visual Basic
Public Shared Sub CvGrabCut ( _
	img As IntPtr, _
	mask As IntPtr, _
	ByRef rect As Rectangle, _
	bgdModel As IntPtr, _
	fgdModel As IntPtr, _
	iterCount As Integer, _
	type As GRABCUT_INIT_TYPE _
)
Visual C++
public:
static void CvGrabCut(
	IntPtr img, 
	IntPtr mask, 
	Rectangle% rect, 
	IntPtr bgdModel, 
	IntPtr fgdModel, 
	int iterCount, 
	GRABCUT_INIT_TYPE type
)

Parameters

img
Type: System..::..IntPtr
The image to be segmented
mask
Type: System..::..IntPtr
The mask to initialize segmentation
rect
Type: System.Drawing..::..Rectangle%
The rectangle to initialize the segmentation
bgdModel
Type: System..::..IntPtr
The background model
fgdModel
Type: System..::..IntPtr
The foreground model
iterCount
Type: System..::..Int32
The number of iternations
type
Type: Emgu.CV.CvEnum..::..GRABCUT_INIT_TYPE
The initilization type

See Also