Ole,
I had done a similar MIDI conversion to AN using HTML5 Canvas--
allowing web printing of scores with shaded/colored staves, for example--
but never got around to posting it.
I had written a Java program to convert a midicsv file to xhtml tags.
One problem was I could never get consistent control of the page layout and page breaks in HTML5. It seems to be browser dependent.
I had also started investigating MIDI conversion in Lilypond.
Problem areas are mapping of "continuous" controllers, such as tempo and volume,
and voicing--how do you decide between notating multiples voices vs chords?
But Lilypond does have a nice midifile decoder engine (written in Python 2) than could be adapted to a variety of other notations.
Currently I'm limited in creating MIDI files. I'm using Aria Maestosa as piano-roll-to-MIDI,
but the MIDI file options are limited. For example, AM has no anacrusis mechanism.
Of course, most editors are not created for the purpose of generating arbitrary MIDI files.
Meanwhile, I had become distracted by some other projects and haven't done any coding for quite a while.
Musically, I've been devoting more time to chorus than to keyboard,
and with chorus I've never found it worthwhile to do any more notation conversion that writing " d r m f s l t " underneath the notes in the score. I do use piano-roll (Aria Maestosa) to create audio files from the score, for learning parts.
My favorite editor was the original Cakewalk, before they converted it from MIDI to audio.
AM is the closest I've found to that, but I dearly miss some of the old Cakewalk features.
Joe