Skip to content

LineStream beta ​

Class of @v12-engine/client/lite-views

ts
export declare class LineStream

Lines in the world a few pixels wide whatever their distance, said again every frame: clear, line…, flush

Members ​

constructor ​

ts
constructor(renderer: Renderer, options: LineStreamOptions);

Constructs a new instance of the LineStream class

clear ​

ts
clear(): void;

No line said yet this frame

dispose ​

ts
dispose(): void;

Takes away its stream and its uniforms

flush ​

ts
flush(width: number, height: number): void;

Sends the frame's lines to be drawn on a view width by height pixels, in which a line's width is counted

line ​

ts
line(ax: number, ay: number, az: number, bx: number, by: number, bz: number, width: number, colour: readonly number[], alpha?: number): void;

A segment this frame; left out past the stream's capacity

path ​

ts
path(points: ArrayLike<number>, width: number, colour: readonly number[], alpha?: number, closed?: boolean): void;

A line through points in turn (three numbers each), joined back to the first where closed

segments ​

ts
segments(points: ArrayLike<number>, width: number, colour: readonly number[], alpha?: number): void;

Segments by their ends one after the other (six numbers a segment), all of a width and a colour