DriftTexture · function

normaliseSample

Write one raw channel value into its component of out, with its convention already applied.

Explained in DriftTexture.

function normaliseSample(out: Float32Array, spec: ChannelSpec, raw: number): void
import { normaliseSample } from '@driftengine/texture';

Parameters

ParameterTypeDescription
outFloat32Array
specChannelSpec
rawnumber

In depth

A consumer of this never asks which way a normal points or which curve an albedo carries.