Not parsing correctly
I have run into bugs with this parser...
I made a simple midi region in LogicPro with notes one tick apart. I export this region as type 0 midi file. When I parse this midi file with midi-parse-js and log the parsed JSON immediately, it is showing incorrect structure in the JSON structure. the notes are being parsed as meta events with -1 deltaTime... I don't know how to attach the midi file to this ticket but if you ask me for it I can send it in email.
{
"formatType": 0,
"tracks": 1,
"track": [
{
"event": [
{
"deltaTime": 0,
"type": 255,
"metaType": 32,
"data": 0
},
{
"deltaTime": 16259,
"type": 255,
"metaType": 6,
"data": "nst 1\u0000ÿ\u0004\u0006Inst 1\u0000ÿX\u0004\u0004\u0002\u0018\b\u0000ÿY\u0002\u0000\u0000\u0000ÿT\u0005!\u0000\u0000\u0000\u0000\u0000ÿQ\u0003\u0007¡ \u0000<P\u0000=P\u0000>P\u0000?P\u0000@P\u0000APx<\u0000\u0000=\u0000\u0000"
},
{
"deltaTime": 62,
"type": 255,
"metaType": 0,
"data": -1
},
{
"deltaTime": 63,
"type": 255,
"metaType": 0,
"data": -1
},
{
"deltaTime": 64,
"type": 255,
"metaType": 0,
"data": -1
},
{
"deltaTime": 65,
"type": 255,
"metaType": 0,
"data": -1
},
{
"deltaTime": -1
}
]
}
],
"timeDivision": 480
}
Hi @steveschow you can send me the .midi file to [email protected] so i can analyse better what's causing the issue. Thanks for reporting the bug!
Hello! Thanks for making this library. I'm also having issues with a simple MIDI file from logic. I just get one event with infinity as the value:
{
formatType: 0,
tracks: 1,
track: [
{
event: [
{ deltaTime: 1440, type: 255, metaType: 32, data: 0 },
{
deltaTime: 16259,
type: 255,
metaType: 23,
data: 2.8996905316392495e+160
},
{ deltaTime: 2123, type: 255, metaType: 98, data: Infinity },
{ deltaTime: -1 }
]
}
],
timeDivision: 480
}
I'll send you the MIDI file. Thanks!