This sample illustrates how to use CoreAudio to load and play a MIDI sequence from a file, and uses an AUGraph to play the notes with an instrument effect. A Virtual Endpoint is also created to interecept and display the MIDI messages as it runs. The sample is a port the 'MIDI Driven Animation using CoreMIDI in Objective C' sample code by Ben Smiley.
Original by Ben Smiley - http://www.deluge.co/?q=midi-driven-animation-core-audio-objective-c
Ported by Timothy Risi