Renderer · function
bakeProbeVisibility
Fill one probe's map from what it can see.
Explained in Hello world.
function bakeProbeVisibility(visibility: ProbeVisibility, layer: number, distanceInDirection: (x: number, y: number, z: number) => number): voidimport { bakeProbeVisibility } from '@driftengine/core';Parameters
| Parameter | Type | Description |
|---|---|---|
visibility | ProbeVisibility | |
layer | number | |
distanceInDirection | (x: number, y: number, z: number) => number |
In depth
distanceInDirection is the bake: how far the geometry is from this probe along a direction.
Given as a callback because how that is measured is the caller's business — a traceField march
offline, a depth cube read back, or a closed form in a test.