Skip to content

Class: BoxLayer

Defined in: layers/box.ts:78

A drawable data series backed by GPU buffers.

Implements

Constructors

Constructor

ts
new BoxLayer(gl, opts): BoxLayer;

Defined in: layers/box.ts:101

Parameters

ParameterType
glWebGL2RenderingContext
optsBoxOptions

Returns

BoxLayer

Properties

id

ts
readonly id: string;

Defined in: layers/box.ts:79

Implementation of

Layer.id


yAxis

ts
readonly yAxis: string;

Defined in: layers/box.ts:80

The y axis this layer is bound to.

Implementation of

Layer.yAxis

Methods

bounds()

ts
bounds(): 
  | {
  x: Range;
  y: Range;
}
  | null;

Defined in: layers/box.ts:231

Data-space bounds of this layer, for autoscaling. null if empty.

Returns

| { x: Range; y: Range; } | null

Implementation of

Layer.bounds


dispose()

ts
dispose(): void;

Defined in: layers/box.ts:257

Returns

void

Implementation of

Layer.dispose


draw()

ts
draw(state): void;

Defined in: layers/box.ts:236

Parameters

ParameterType
stateDrawState

Returns

void

Implementation of

Layer.draw


setData()

ts
setData(groups, width?): void;

Defined in: layers/box.ts:224

Replace the box groups and rebuild the geometry (for streaming).

Parameters

ParameterType
groupsBoxGroup[]
width?number

Returns

void

MIT licensed. WebGL2 required.