API

Interface PointerVisual

Pure result of computePointerVisual: where the beam and cursor go.

interface PointerVisual {
    beamLength: number;
    cursorPosition: [number, number, number];
    hit: boolean;
    laserPosition: [number, number, number];
}
Index
beamLength: number

Beam length in metres — the hit distance, or maxLength on a miss.

cursorPosition: [number, number, number]

World-space cursor position — meaningful only when hit.

hit: boolean

True when the ray hit a mesh (cursor is shown).

laserPosition: [number, number, number]

World-space centre of the laser box.