Class: Bar3DLayer
Defined in: plot3d/bar3d.ts:91
3D bars (columns) on an x/z grid, lit like the surface and optionally colormapped.
Implements
Constructors
Constructor
new Bar3DLayer(gl, opts): Bar3DLayer;Defined in: plot3d/bar3d.ts:113
Parameters
| Parameter | Type |
|---|---|
gl | WebGL2RenderingContext |
opts | Bar3DOptions |
Returns
Bar3DLayer
Properties
colorCss?
readonly optional colorCss?: string;Defined in: plot3d/bar3d.ts:94
A solid CSS color for the legend swatch (solid-colored layers only).
Implementation of
id
readonly id: string;Defined in: plot3d/bar3d.ts:92
Implementation of
name?
readonly optional name?: string;Defined in: plot3d/bar3d.ts:93
Series name for the legend (optional).
Implementation of
Methods
bounds3()
bounds3(): Bounds3 | null;Defined in: plot3d/bar3d.ts:202
Returns
Bounds3 | null
Implementation of
colorInfo()
colorInfo(): ColorInfo | null;Defined in: plot3d/bar3d.ts:204
Colormap + value range for a colorbar, if this layer is colormapped.
Returns
ColorInfo | null
Implementation of
dispose()
dispose(): void;Defined in: plot3d/bar3d.ts:226
Returns
void
Implementation of
draw()
draw(gl, mvp): void;Defined in: plot3d/bar3d.ts:214
Parameters
| Parameter | Type |
|---|---|
gl | WebGL2RenderingContext |
mvp | Mat4 |
Returns
void
Implementation of
pickData()
pickData():
| {
positions: Float32Array<ArrayBufferLike>;
}
| null;Defined in: plot3d/bar3d.ts:206
Data-space points for hover picking (xyz triples), with an optional per-point tooltip label builder. Null if the layer isn't pickable.
Returns
| { positions: Float32Array<ArrayBufferLike>; } | null
Implementation of
setData()
setData(
x,
z,
y): void;Defined in: plot3d/bar3d.ts:198
Stream new bar positions/heights (instances rebuilt). Call plot.refresh() after.
Parameters
| Parameter | Type |
|---|---|
x | ArrayLike<number> |
z | ArrayLike<number> |
y | ArrayLike<number> |
Returns
void
setLight()
setLight(dir, ambient): void;Defined in: plot3d/bar3d.ts:209
Set the light direction (world space) and ambient term (0..1).
Parameters
| Parameter | Type |
|---|---|
dir | [number, number, number] |
ambient | number |
Returns
void