Platform Independent Library for MIDI I/O

PortMedia is supported by the
National Science Foundation

PortMidi is a library for software developers. It supports real-time input and output of MIDI data using a system-independent interface. PortMidi runs on Windows (using MME), Macintosh (using CoreMIDI), and Linux (using ALSA).


The primary documentation is contained in the main header file, portmidi.h. You can find this in the sources when you download the PortMidi library, or you can see the latest version in the SVN repository.

There is also documentation generated by Doxygen. This documentation still needs some work, but you might like it.


You can download PortMidi here.

Source Code and Development with SVN

PortMidi sourcecode is maintained on SourceForge using Subversion (SVN). You can get the latest PortMidi source code through SVN. (See the PortMidi Wiki for instructions.)

PortMidi Wiki

PortMidi, as part of the PortMedia project on SourceForge, has a Wiki. Visit the PortMidi Wiki pages for more information about PortMidi.

PmDefaults Application

Applications that use PortMidi often face the problem of choosing among multiple MIDI input and output devices. To simplify life for application developers and to offer a reasonable interface to application users, PortMidi includes an application, PmDefaults, which can be used to set device preferences. Since PmDefaults is intended for end users, it is offered as an installer for Windows and a ready-to-run application for Mac OS X. You can read more about it on the Wiki.