Skip to content

five-on-it / apps/client/src/renderer/lasers-view / composeBeam

Function: composeBeam() ​

composeBeam(from, to, width, out, offset): number

Defined in: apps/client/src/renderer/lasers-view.ts:62

Writes the matrix of a beam from from to to, width wide, into out at offset: a unit box stretched along the way between them, its middle half way. Returns the beam's length (m); a beam shorter than a centimetre is written as nothing (all zeros).

Parameters ​

from ​

Point

to ​

Point

width ​

number

out ​

Float32Array

offset ​

number

Returns ​

number