Renderer · function
octahedralEdgeFor
The octahedral edge a probe of a given cube face size gets.
Explained in Hello world.
function octahedralEdgeFor(faceSize: number): numberimport { octahedralEdgeFor } from '@driftengine/core';Parameters
| Parameter | Type | Description |
|---|---|---|
faceSize | number |
In depth
Twice the face, which is the ratio OCTAHEDRAL_EDGE already chose for the point-shadow
array and for the reason written down there: matching a cube face's angular density needs
face * sqrt(6), so twice the face is about 1.22x coarser in the worst direction, taken
because the filtering this unlocks is blurring the result anyway. 1024 for a 512 face there,
256 for the default 128 face here — one rule, so the two octahedral resources in this engine
are calibrated against each other rather than each to taste.