Constructors
constructor
- new Point(x?, y?): Point
Parameters
Optional
x: number
Optional
y: number
Methods
distance
- distance(other): number
Returns number
distanceSquare
- distanceSquare(other): number
Returns number
dot
- dot(other): number
Returns number
equal
- equal(other): boolean
Returns boolean
fromArray
- fromArray(input): void
Returns void
len
- len(): number
Returns number
lenSquare
- lenSquare(): number
Returns number
scale
- scale(scalar): void
Returns void
scaleAndAdd
- scaleAndAdd(other, scalar): void
Returns void
toArray
- toArray(out): number[]
Returns number[]
Static
add
- add(out, p0, p1): void
Returns void
Static
copy
- copy(p, p2): void
Returns void
Static
dot
- dot(p0, p1): number
Returns number
Static
len
- len(p): number
Returns number
Static
lenSquare
- lenSquare(p): number
Returns number
Static
lerp
- lerp(out, p0, p1, t): void
Returns void
Static
scale
- scale(out, p0, scalar): void
Returns void
Static
scaleAndAdd
- scaleAndAdd(out, p0, p1, scalar): void
Returns void
Static
set
- set(p, x, y): void
Returns void
Static
sub
- sub(out, p0, p1): void
Returns void
Add another point