Try another thing, too:
And see if it fixes the issue you are having (I indeed should have put that, since it's a 4 byte variable, and cannot be negative, according to the MIDI standard)
VANYA wrote: ↑Oct 19, 2022 15:30
And by the way, I'll remind you of my question:
angros47! Your sequencer.bi file writed:
const MaxTracks=16
I am not an expert in MIDI, but one person who knows a little about it said that this is a limitation and maybe not all midi files will be able to play. This is true?
No, it is not true: MIDI can have at most 16 channels (it cannot have more, because each midi event is represented by a byte: the most significant 4 bits are the event, the least significant 4 are the channel number, and with 4 bits you cannot represent more than 16 numbers, so no more than 16 channels can be included without changing the MIDI format and breaking compatibility).
And MIDI files are usually of two formats (
https://www.music.mcgill.ca/~ich/classe ... html#BM2_2): format 0 has only one track, that contains events of all channels, and format 1 has one track per channel (since channels cannot be more than 16, there cannot be more than 16 tracks). There is also a third format, called format 2, that allows to have different musics in the same MIDI file, but it's almost never used, and many trackers don't even support it.
So, MIDI files that are compliant to the supported formats will never have more than 16 tracks