Emgu CV Library Documentation
cvDistTransform Method (src, dst, distanceType, maskSize, userMask, labels)
NamespacesEmgu.CVCvInvokecvDistTransform(IntPtr, IntPtr, DIST_TYPE, Int32, array<Single>[]()[], IntPtr)

www.emgu.com/wiki
Calculates distance to closest zero pixel for all non-zero pixels of source image
Declaration Syntax
C#Visual BasicVisual C++
public static void cvDistTransform(
	IntPtr src,
	IntPtr dst,
	DIST_TYPE distanceType,
	int maskSize,
	float[] userMask,
	IntPtr labels
)
Public Shared Sub cvDistTransform ( _
	src As IntPtr, _
	dst As IntPtr, _
	distanceType As DIST_TYPE, _
	maskSize As Integer, _
	userMask As Single(), _
	labels As IntPtr _
)
public:
static void cvDistTransform(
	IntPtr src, 
	IntPtr dst, 
	DIST_TYPE distanceType, 
	int maskSize, 
	array<float>^ userMask, 
	IntPtr labels
)
Parameters
src (IntPtr)
Source 8-bit single-channel (binary) image.
dst (IntPtr)
Output image with calculated distances (32-bit floating-point, single-channel).
distanceType (DIST_TYPE)
Type of distance
maskSize (Int32)
Size of distance transform mask; can be 3 or 5. In case of CV_DIST_L1 or CV_DIST_C the parameter is forced to 3, because 3x3 mask gives the same result as 5x5 yet it is faster.
userMask (array< Single >[]()[])
User-defined mask in case of user-defined distance. It consists of 2 numbers (horizontal/vertical shift cost, diagonal shift cost) in case of 3x3 mask and 3 numbers (horizontal/vertical shift cost, diagonal shift cost, knights move cost) in case of 5x5 mask.
labels (IntPtr)
The optional output 2d array of labels of integer type and the same size as src and dst.

Assembly: Emgu.CV (Module: Emgu.CV) Version: 1.3.0.0 (1.3.0.0)