MFLoadSequence
Loads a sequence from a MIDI file.
Synopsis
Err MFLoadSequence( MIDIFileParser *mfpptr, char*filename, Sequence *SeqPtr )
Description
This function loads a single sequence from a Format 0 MIDI file and turns it into a Juggler sequence for playback using the Juggler. To use this function, you must first create the Juggler sequence using CreateObject()
. The function translates the MIDI messages in the sequence into MIDI events in the Juggler sequence. To work, the function must have a MIDIFileParser data structure to keep track of the MIDI sequence's original settings.
Note that this function will accept a Format 1 MIDI file, in which case it converts only the first track (sequence) of the file. That track typically contains no notes.
Arguments
- mfpptr
- Pointer to a MIDIFileParser data structure.
- filename
- Pointer to a character string containing the name of the Format 0 MIDI file from which to load the sequence.
- SeqPtr
- Pointer to a Juggler sequence in which to store the converted MIDI sequence.
Return Value
This function returns 0 if successful or an error code (a negative value) if an error occurs.
Implementation
Library call implemented in music.lib V20.
Associated Files
score.h, music.lib
See Also
CreateObject
(), MFLoadCollection(), MFUnloadCollection()