Skip to main content

sonic_token_to_midi

Function sonic_token_to_midi 

Source
pub fn sonic_token_to_midi(token: u64) -> Option<MidiMessage>
Expand description

Decode a packed sonic-token u64 back into a MidiMessage.

Returns None if the token’s event type is SonicEventType::Parametric (no MIDI equivalent) or if a decoded field is out of MIDI range (note or value > 127). Channel is always in range (4-bit field).