Returns a function to interpolate between colours
import { Colour } from 'https://unpkg.com/ixfx/dist/visual.js'const i = interpolator([`orange`, `yellow`, `red`]);// Get a random colour on the above spectrumi(Math.random()); Copy
import { Colour } from 'https://unpkg.com/ixfx/dist/visual.js'const i = interpolator([`orange`, `yellow`, `red`]);// Get a random colour on the above spectrumi(Math.random());
Results will vary depending on the colour space used, play with the options. When using a hue-based colour space, the hue option sets the logic for how hue values wrap.
hue
interpolator([`orange`, `yellow`, `red`], { space: `hsl`, hue: `longer }) Copy
interpolator([`orange`, `yellow`, `red`], { space: `hsl`, hue: `longer })
Colours to interpolate between
Options for interpolation
Returns a function to interpolate between colours
Results will vary depending on the colour space used, play with the options. When using a hue-based colour space, the
hue
option sets the logic for how hue values wrap.