benilla-re systems structs docs

s_screenAspect

global · screencoord

Address
0x832a40 · 4 bytes, up to 0x832a43
Type
float
Meaning
Holds the configured display aspect a, stored by 0x41ad10
Confidence
verified, proof two
Finding
screencoord#screen-scale-state

Finding: Screen scale state in screencoord

0x41ad10 takes the display aspect a, a float, on the stack (ret 4) and sets four floats. With RN24 rounding to float and L = 1/√(a² + 1) computed at 53 bits:

globalvalue
0x832a40a, the dword as passed
0x832a44K1 = RN24(a·L), the screen's width in layout units
0x832a48K2 = RN24(L), the screen's height in layout units
0x832a4cA = RN24(0.75·a)

(K1, K2) is the unit vector along (a, 1), so the screen's diagonal is one layout unit. The file holds 4/3's values except K2: a 1.3333334, K1 0.8 (0x3f4ccccd), K2 0.6 (0x3f19999a), A 1.0; a call with RN24(4/3) stores K2 as 0x3f199999. 0x41ad70 returns A in st0.

The derivation is in the doc.