Click or drag to resize

MathHelperPointLineDistance Method (Vector2, Vector2, Vector2)

imbVeles Framework: imbSCI | imbACE | imbNLP | imbWEM | imbWBI
Calculates the minimum distance between a point and a line.

Namespace:  netDxf
Assembly:  netDXF.Standard (in netDXF.Standard.dll) Version: 2.1.1
Syntax
C#
public static double PointLineDistance(
	Vector2 p,
	Vector2 origin,
	Vector2 dir
)
Request Example View Source

Parameters

p
Type: netDxfVector2
A point.
origin
Type: netDxfVector2
Line origin point.
dir
Type: netDxfVector2
Line direction.

Return Value

Type: Double
The minimum distance between the point and the line.
See Also