write a MIDI file in C++
Hi I Have some problems finding the right info开发者_StackOverflow社区rmation about this and would be glad if someone could point me in the right direction. How do you code a midifile? e.g. how can I write a snippet that plays a random tone for 1 second. Basically what I would need to get done is representing differnet midi melodys as vectors of some sort? How can I do this..
You could also read up on the MIDI file spec (quick search turned up this) and generate the file yourself. Using a library is probably easier, but the MIDI file format isn't too complicated, especially if you already know how MIDI works (eg. note on/note off messages).
精彩评论