Skip to main content

midi_file

Function midi_file 

Source
pub fn midi_file(
    events: impl IntoIterator<Item = MidiEvent>,
) -> Result<Arc<MidiFile>, VoiceError>
Expand description

Builds a MIDI file from timed messages, ready for MidiSequencer::new.

The events may come in any order: they are sorted by time, and events at the same time keep the order they were given in.

ยงErrors

Returns the MIDI error when a time is not a number.