C ++ MIDI File Reading Library

I am trying to write some software to read a MIDI file into an internal data format and use it to control 3D simulated instruments. My biggest problem is reading MIDI data from a file, and I would like not to write all the import code.

Does anyone know of a free (preferably Open Source), cross-platform library for reading MIDI files? What features does it have? Can it import other music formats based on notes?

+4
source share
2 answers

I once wrote a Midi file read / write library in C. If you want to look here, this is: http://code.google.com/p/middl/

This is a very simple library that allows you to define a callback function for each type of MIDI event, for C ++ you can encapsulate it in some kind of "Midi reader" class (or just use it as it is :).

+3
source

You can try Timidity, an open source midi player written in c. Its pretty easy to hack what you want.

+1
source

Source: https://habr.com/ru/post/1305734/


All Articles