Renderer · function

conventionalDepth

Turn a depth read out of the buffer back into the [0, 1] a conventional one would have held.

Explained in Hello world.

function conventionalDepth(stored: number): number
import { conventionalDepth } from '@driftengine/core';

Parameters

ParameterTypeDescription
storednumber

In depth

For anything that reconstructs a position or a distance from stored depth and was written against the conventional sense. One place, so a pass that forgets it is a pass that looks wrong rather than one that quietly disagrees with its neighbour.