Skip to content

API / Point

Class: Point

Defined in: geom/Point.ts:31

The Point object represents a location in a two-dimensional coordinate system.

Constructors

Constructor

ts
new Point(x: number, y: number): Point;

Defined in: geom/Point.ts:63

Creates a new point. If you pass no parameters to this method, a point is created at (0,0).

Parameters

ParameterTypeDefault valueDescription
xnumber0.0The horizontal coordinate.
ynumber0.0The vertical coordinate.

Returns

Point

Properties

x

ts
x: number;

Defined in: geom/Point.ts:40

The horizontal coordinate.

Default

ts
0.0

y

ts
y: number;

Defined in: geom/Point.ts:49

The vertical coordinate.

Default

ts
0.0

Released under the MIT License.