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