Skip to main content
← PSoXide SDK guides and examples · SDK f2fec1c301f1 · All Cargo features enabled; check feature gates before use.

pack_xy

Function pack_xy 

Source
pub const fn pack_xy(x: i16, y: i16) -> u32
Expand description

Helper: pack two i16 values into one u32 for MTC2/CTC2 of XY-pair registers (V0 X/Y, SXY slots, rotation matrix rows, …).

The low 16 bits hold x, the high 16 bits hold y.