-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add examples on how to write LiveEvents to mid files #24
Comments
Also I wonder if it's possible to write mid files streaming chunks of event data instead of writing the whole file at once. This way you could save up some memory space especially when you've got many tracks or making long recordings. |
The reason why a
Timing info is not so easy to work with in MIDI, but it involves adding a timing message at the beggining of track 0 which defines the unit of time used in the file (a "tick"), and then converting the times at which the events happen to delta ticks. I agree it would be nice to have a set of examples. If I have some spare time I will add some. If you (or any reader) has figured it out and has some spare time, feel free to add examples. |
I've figured this one out. Managed to make a working POC where midi events can be recorded and saved to a |
I'm trying to write events, coming from jack midi input port, to a mid file. I guess I could say I'm trying to record a midi sequence. The documentation doesn't really have much info nor any examples on how to write live event sequences to mid files.
I still tried and couldn't figure out how to convert LiveEvent to TrackEvent, so I could write it.
I've set up an SMF:
and then tried to push an event to the first track:
But
as_track_event
returnsTrackEventKind
and I can't find no way to convert that.The text was updated successfully, but these errors were encountered: