If y'all think midi file read/write support is appropriate, I can move the code to do that from grig.midi to here