benilla-re systems structs docs

CSimpleColorSelect::Redraw

function · ui · primitive

Address
0x78bae0 · 189 bytes, up to 0x78bb9c
Meaning
Redraws the colour select and runs OnColorSelect with red, green and blue
Confidence
verified, proof one
Finding
ui/colorselect#reading-the-colour
Test
ui::glue_geom_78bae0_color_channels

Finding: Reading the colour in ui: ColorSelect

OnColorSelect gets the colour as red, green and blue, and GetColorRGB returns the same three: the colour converted back to channels, each made a byte by adding 512 to v·255, rounding the sum to a float and keeping its integer part, then divided by 255. The float holds the sum to the nearest 1/16384, so a channel can read back one step below what SetColorRGB stored, and one within 1/32768 below a whole step reads back as that step. GetColorHSV returns the three fields as they are. A grey colour has no hue: converting one with saturation 0 stores the hue −1, so after SetColorRGB of a grey GetColorHSV returns −1 as the hue.

The derivation is in the doc.

Callers 3

Callees 6

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