benilla-re systems structs docs

CombineCenter

function · ui · primitive

Address
0x7672d0 · 141 bytes, up to 0x76735c
Meaning
Returns (near+far)·0.5, near+d·0.5 or far−d·0.5, or +inf, by which inputs are finite
Confidence
verified, proof one
Finding
ui/anchors#edge-resolution-from-size
Test
ui::layout_combine_center

Finding: Edge resolution from size in ui: anchors and layout

When no point fixes an edge it is derived from its size d, the frame's width (slot 0x1c, +0x50) or height (slot 0x20, +0x54) times the scale +0x58, rounded to a float. A far edge (right, top) is near + d, else centre + d·0.5, else 2·centre − near; a near edge (left, bottom) is the same with −d. The first two steps need their inputs to be finite (not +∞) and d nonzero; the last is reached only when d is 0 and needs both the centre and the near edge finite. A centre is (near + far)·0.5, else near + d·0.5, else far − d·0.5; the last two need d nonzero. Otherwise the result is +∞.

The derivation is in the doc.

Callers 2

Callees 0

None by a direct call or jump.

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