Emgu CV Library Documentation
cvFitLine Method (points, distType, param, reps, aeps, line)
NamespacesEmgu.CVCvInvokecvFitLine(IntPtr, DIST_TYPE, Double, Double, Double, array<Single>[]()[])

www.emgu.com/wiki
Fits line to 2D or 3D point set
Declaration Syntax
C#Visual BasicVisual C++
public static void cvFitLine(
	IntPtr points,
	DIST_TYPE distType,
	double param,
	double reps,
	double aeps,
	float[] line
)
Public Shared Sub cvFitLine ( _
	points As IntPtr, _
	distType As DIST_TYPE, _
	param As Double, _
	reps As Double, _
	aeps As Double, _
	<OutAttribute> line As Single() _
)
public:
static void cvFitLine(
	IntPtr points, 
	DIST_TYPE distType, 
	double param, 
	double reps, 
	double aeps, 
	[OutAttribute] array<float>^ line
)
Parameters
points (IntPtr)
Sequence or array of 2D or 3D points with 32-bit integer or floating-point coordinates
distType (DIST_TYPE)
The distance used for fitting
param (Double)
Numerical parameter (C) for some types of distances, if 0 then some optimal value is chosen
reps (Double)
Sufficient accuracy for radius (distance between the coordinate origin and the line), 0.01 would be a good default
aeps (Double)
Sufficient accuracy for angle, 0.01 would be a good default
line (array< Single >[]()[])
The output line parameters. In case of 2d fitting it is array of 4 floats (vx, vy, x0, y0) where (vx, vy) is a normalized vector collinear to the line and (x0, y0) is some point on the line. In case of 3D fitting it is array of 6 floats (vx, vy, vz, x0, y0, z0) where (vx, vy, vz) is a normalized vector collinear to the line and (x0, y0, z0) is some point on the line.

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