Skip to content

mxm, IT's mad science

Sections
Personal tools
You are here: Home » Products » Open Source » Python Midi Package » How to create more then 1 track.
Downloads
You can download mxm products here.

Due to it's technical and international nature, this section is in english.

Max M Has a blog too.

og er glad for mad

 

Comment

Above in this comment thread: Python Midi Package

How to create more then 1 track.

Posted by Anonymous User at 2006-02-11 06:02 PM
I am not sure, how to create more then 1 track in the midi song. I was trying the following:
start_of_track(0)
... (some note_on and note_off events)
end_of_track()
start_of_track(1)
... (some note_on and note_off events) ...
end_of_track()
Did not work.
Then I tried:
start_of_track(0)
start_of_track(1)
set_current_track(0)
... (some note_on and note_off events) ...
set_current_track(1)
... (some note_on and note_off events)
end_of_track()
Still does not work. In both cases only 1 track is created and all notes are on the same track.
Would greatly appreciate, if anybody could give me a short example, how to create multiple tracks.
Thanks so much.

I also need help doing this

Posted by Anonymous User at 2008-01-01 09:01 PM
I am having the same problems - does anyone have an example for creating a midi file with multiple concurrent tracks? My current code creates 2 tracks (when I import to garage band) but all the notes are written to the first track!