Table of Contents

Method DistancePointToLine

Namespace
Pinwheel.Vista
Assembly
Pinwheel.Vista.Runtime.dll

DistancePointToLine(Vector2, Vector2, Vector2)

Computes the perpendicular distance from a point to the infinite line passing through two points.

public static float DistancePointToLine(Vector2 l1, Vector2 l2, Vector2 p)

Parameters

l1 Vector2

First point on the line.

l2 Vector2

Second point on the line.

p Vector2

Point to measure from.

Returns

float