benilla-re systems structs docs

SimpleModelLightCallback

function · ui · primitive

Address
0x76d680 · 368 bytes, up to 0x76d7ef
Meaning
Stages the frame's fog and, when enabled, its light into the scene model's light collector
Confidence
verified, proof one
Finding
ui/modelanim#fog
Test
ui::glue_76d680_color_pack

Finding: Fog in ui: Model frames, animation, light and fog

A model frame can fog its model. SetFogColor(r, g, b[, a]) clamps each component to [0, 1] (NaN to 1), packs 0xAARRGGBB with trunc(c·255 + 0.5) (alpha defaults to 1.0) and arms the fog; SetFogNear and SetFogFar store a number as it is; ClearFog clears the arm bit only, leaving colour, near and far. The XML attributes fogNear and fogFar are clamped at 0 and FogColor sets the colour and arms the fog. The fog applies per material: a material marked unfogged ignores it, and the fog is on only for far > near.

The derivation is in the doc.

Callers 0

None by a direct call or jump.

Callees 4

Calls and jumps by a bare address, from tables/calls.tsv.