Renderer · interface
SpatialOptions
Explained in Hello world.
interface SpatialOptionsimport type { SpatialOptions } from '@driftengine/core';Properties
| Name | Type | Description |
|---|---|---|
stepreadonly | number | Multiplier on the kernel's spacing, in pixels. See filterStepFor for what chooses it.MoreA step rather than a radius, which is the à-trous arrangement: the same five-tap kernel is run with its taps further apart, so a wide filter costs what a narrow one costs. A radius would cost its own square. |
depthTolerancereadonlyoptional | number | How far apart in depth two pixels may be and still share light, as a fraction of their depth.MoreRelative rather than absolute, because a centimetre is a discontinuity across a desk and nothing at all across a valley. A tenth is wide enough to keep a surface tilted away from the camera together and narrow enough to find the edge of the thing standing on it. |
normalSharpnessreadonlyoptional | number | The exponent on max(dot(n, n'), 0). Higher keeps the filter inside one face. |