wyskoj / midis2jam2

🎶 A remaster of MIDIJam, a 3D MIDI file visualizer.
https://midis2jam2.xyz
GNU General Public License v3.0
165 stars 21 forks source link

RealTimeSequencer drifts out of sync when tempo events occur #181

Closed peppinodoesmidi closed 8 months ago

peppinodoesmidi commented 9 months ago

so while i was making deathdeservioli midi from pizza tower i tested it with midis2jam2 but when the bpm slide started it was going so slow and the instruments weren’t playing in the right place or time so i hope you can fix this

wyskoj commented 9 months ago

@peppinodoesmidi Please provide a MIDI file that causes the issue you describe. (You will need to ZIP it before uploading because GitHub does not allow MIDI files to be uploaded.)

saverofthewos commented 9 months ago

This happens with any midi with a BPM slide, for example [Black MIDI] RUSH E (Fully RECREATED).zip plays too fast.

peppinodoesmidi commented 8 months ago

oh ok i'll try to do taht

peppinodoesmidi commented 8 months ago

what i meant was there was a bpm slide glitch deservioli.mid.zip idk if you can download the zip or not but i hope this works

wyskoj commented 8 months ago

I've boiled this down to a bug in the OpenJDK RealTimeSequencer implementation of Sequencer. Although it's an upstream issue, I'm going to attempt to fork it and implement my own fix.

wyskoj commented 8 months ago

This happens with any midi with a BPM slide, for example [Black MIDI] RUSH E (Fully RECREATED).zip plays too fast.

@saverofthewos That MIDI file doesn't have any tempo changes.

saverofthewos commented 8 months ago

This happens with any midi with a BPM slide, for example [Black MIDI] RUSH E (Fully RECREATED).zip plays too fast.

@saverofthewos That MIDI file doesn't have any tempo changes.

It did when I downloaded it

wyskoj commented 8 months ago

@saverofthewos Here's a CSV readout of that MIDI file.

[Black MIDI] RUSH E (Fully RECREATED).csv

If you filter the event column to only show tempo events, you can see that there is only one event.

image

saverofthewos commented 8 months ago

That's weird. The website I downloaded it from had a tempo slide.

peppinodoesmidi commented 8 months ago

wait but i used fl studio for the tempo slide for the midi

wyskoj commented 8 months ago

wait but i used fl studio for the tempo slide for the midi

The issue doesn't lie with the software package used to create the MIDI file.

I'm working on a fix.

peppinodoesmidi commented 8 months ago

oh ok

wyskoj commented 8 months ago

This required a complete overhaul of the existing sequencer. Fix will be published in the next version.

peppinodoesmidi commented 8 months ago

k