Skip to content

Function: colormap() ​

ts
function colormap(spec?): (t) => RGB;

Defined in: color/colormap.ts:208

Returns a (t in 0..1) => RGB sampler (LUT-backed). Accepts a built-in or registered name, or inline anchor colours.

Parameters ​

ParameterTypeDefault value
specColormapSpec"viridis"

Returns ​

(t) => RGB

MIT licensed. WebGL2 required.