Point2D

Methods
2
Fields
2

Methods

MethodReturnsDescription
distance(number, number, number, number)numberThe Euclidean distance from (x1, y1) to (x2, y2), as AWT computes it.
distanceSq(number, number, number, number)numberThe squared distance from (x1, y1) to (x2, y2).

Fields

FieldTypeDescription
DoublePoint2DClassPoint2D.Double: Point2D itself, for its statics; it has no new (no Point2D object is made).
FloatPoint2DClassPoint2D.Float: Point2D itself, for its statics; it has no new (no Point2D object is made).

Method details

distance

distance: (number, number, number, number) -> number

The Euclidean distance from (x1, y1) to (x2, y2), as AWT computes it.

distanceSq

distanceSq: (number, number, number, number) -> number

The squared distance from (x1, y1) to (x2, y2).