Interface: LocalLightsOptions
Properties
analyticRadius
• analyticRadius: number
Blocks from the camera within which lights become analytic.
csmFarCascadeUnits
• csmFarCascadeUnits: number
Ledger cost of one CSM far cascade, in face units.
csmNearCascadeUnits
• csmNearCascadeUnits: number
Ledger cost of the CSM near cascade, in face units.
fadingRowReserve
• fadingRowReserve: number
Data rows kept free for lights fading out of the selection, so the selection never has to cut one off mid-fade.
fluidSpecularStrength
• fluidSpecularStrength: number
Strength of local specular on fluids; 0 disables.
gridCellSize
• gridCellSize: number
Grid cell size in blocks.
gridDims
• gridDims: [number, number, number]
Grid cells per axis [x, y, z]; the window scrolls with the camera.
highResolutionHysteresis
• highResolutionHysteresis: number
Fractional band around highResolutionPixels the gate must cross to
flip, so an adaptive render scale hovering at the threshold does not
toggle it every step.
highResolutionLightsPerCell
• highResolutionLightsPerCell: number
highResolutionPixels
• highResolutionPixels: number
Drawing-buffer pixels at and above which a cell keeps at most
highResolutionLightsPerCell steady lights: the per-fragment loop is
paid per pixel, so large buffers can trade light count for frame time.
The default cap is every slot (MAX_LIGHTS_PER_CELL), so a tier keeps
its own per-cell count at any resolution. A cell that drops a lamp
hands it back to its flood, which is dimmer and flat, so a lower cap
draws a straight line along the cell edge wherever three lamps share a
cell: at 2, every retina screen saw it on "high" (16 Oct). Frame time
at 2560x1440 over a three-lamp floor: 6.0 ms at 2, 6.1 ms at 4.
localShadowBias
• localShadowBias: number
Constant occluder-side depth bias in blocks (linear light space).
localShadowNormalBiasTexels
• localShadowNormalBiasTexels: number
Receiver offset along the surface normal, in shadow texels.
localShadowPcfRadius
• localShadowPcfRadius: number
PCF tap spread, in shadow texels.
localShadowStrength
• localShadowStrength: number
1 = an occluded fragment loses the light entirely.
maskKnee
• maskKnee: number
Flood-mask knee: flood level (0..1) at which masked lights reach full.
maxClusteredLights
• maxClusteredLights: number
Lights the clustered layer may select per pass; capped at 255.
maxLightsPerCell
• maxLightsPerCell: number
Grid slots filled per cell; the shader loop is compiled for 8.
maxRegisteredLights
• maxRegisteredLights: number
Pool capacity for registered lights (static emitters + dynamic sources).
maxSectionScansPerFrame
• maxSectionScansPerFrame: number
Sections scanned for emitters per frame at most.
maxShadowedLights
• maxShadowedLights: number
Shadowed local lights at once; each owns a fixed atlas region.
qualityTier
• qualityTier: LightQualityTier
Initial quality tier.
sectionRescanWindowMs
• sectionRescanWindowMs: number
The window, in ms, a section's emitter scans are counted in. A scan
reads the whole section, and a stream of changes (flames spreading
through one) alters its emitters every frame: a section scanned
sectionRescansPerWindow times inside one window waits, still
pending, and is read again when the window closes.
sectionRescansPerWindow
• sectionRescansPerWindow: number
Scans one section may take inside sectionRescanWindowMs. An edit made
in a quiet section is scanned the frame it lands.
selectionHysteresis
• selectionHysteresis: number
Multiplier a light's score gets while selected, against churn.
shadowAtlasSize
• shadowAtlasSize: number
Edge length of the shared depth atlas, in pixels.
shadowEvictionHysteresis
• shadowEvictionHysteresis: Object
A challenger light must out-score a shadow holder by ratio for
frames consecutive frames before evicting it from the atlas.
Type declaration
| Name | Type |
|---|---|
frames | number |
ratio | number |
shadowFadeMs
• shadowFadeMs: number
How long a light's shadow takes to fade in or out, in ms.
shadowLedgerUnitsPerFrame
• shadowLedgerUnitsPerFrame: number
Face units the shadow ledger may spend per frame (CSM + local).
shadowSlotSize
• shadowSlotSize: number
Edge length of one atlas cell (one cube face render), in pixels.
slotFadeMs
• slotFadeMs: number
How long a light takes to fade into or out of a cell, in ms.
windowFadeBlocks
• windowFadeBlocks: number
Width of the window-rim fade, in blocks.