MIDI library

Steev's MIDI Library is a pure C library to handle the MIDI protocol, as well as providing code to read and write standards-compliant MIDI files. This provides code functionality for apps wishing to support MIDI file serialism, as well as write music apps that auto-compose music.

It provides sample code to:

  • Convert MIDI files to RTTTL ring tones (m2rtttl)
  • Dump the contents of MIDI files (mididump)
  • Convert files from version 1 to 0, as some electronic keyboards support only version 0. (mfc120)
  • Auto-generate music, based on "Mozarts Dice" (mozart)

It is a wonderfully compact, and complete, library that contains all the constants necessary to understand the protocol, such as instrument names, drum maps, and controller names & IDs. There's also utility methods to compute the real-world frequency of any given note and guess the currently playing chord.


Download

The full source to MIDI Library is still available!