@pbroom/color-kit/interopReaders
fromOklchArray4
Read a color from OKLCH [l, c, h] stored in any array-like (number[], Float32Array, ...). Alpha is read from the fourth component: [c0, c1, c2, alpha].
import { fromOklchArray4 } from '@pbroom/color-kit/interop';readers.ts:232function fromOklchArray4(
array: ArrayLike<number>,
offset?: number,
): Color;Parameters
Returns
ColorA new Color (OKLCH).
Example
const color = fromOklchArray4(buffer, 8);Also exported from
@pbroom/color-kitthe same declaration, re-exported