Tonejs / Midi

Convert MIDI into Tone.js-friendly JSON
http://tonejs.github.io/Midi/
MIT License
885 stars 117 forks source link

Get marker and lyrics metadata from all tracks #179

Closed baparham closed 1 year ago

baparham commented 1 year ago

I noticed when reading in some multitrack midi files with lyrics attached to a vocals track not in track index 0, that the library didn't pick up the lyrics. Looking at the code it looks like the markers and lyrics are never picked up from tracks other than zero.

I've created a patch that seems to solve the problem for me locally, but perhaps I've missed something important about why this metadata was only ever ready from track 0. I welcome any feedback.

baparham commented 1 year ago

@tambien can you take a peek at this? Does it make sense or were there specific reasons for the existing pattern?

baparham commented 1 year ago

ping @tambien :-)