block by rveciana f1a11a4464ccc1bf57e8010bd2932512

Representing a MIDI file with D3js

Full Screen

Just playing with a MIDI reader: https://github.com/grimmdude/MidiPlayerJS that triggers events that D3 uses to draw an SVG.

A better option would be using d3 to trigger the events too (it would be cleaner).

The “song” score is taken from this page: http://www0.cpdl.org/wiki/index.php/Jesu,_meine_Freude,_BWV_227_(Johann_Sebastian_Bach) and converted to MIDI with MuseScore.

index.js

index.html