API reference

Every public class, method, and event in @codexo/exojs. Generated from source.

C

classLineSegment

@codexo/exojs-particles / particles / stable

Random point on a line segment between `(x0, y0)` and `(x1, y1)`. Uniform parameter distribution: `t = Math.random()` then `lerp(start, end, t)`.

4
props
1
methods
0
events
Import
import { LineSegment } from '@codexo/exojs-particles'

Random point on a line segment between `(x0, y0)` and `(x1, y1)`. Uniform parameter distribution: `t = Math.random()` then `lerp(start, end, t)`.

Constructors 1
new(x0: number, y0: number, x1: number, y1: number): LineSegment
Methods 1
sample(out: Vector): Vector
Properties 4
x0: number
x1: number
y0: number
y1: number
Source