Benno Senoner wrote:
I'm just writing some MIDI file ( SMF 0/1)
loading routines and
while the file structure is quite simple I came across some MIDI files
(mainly .KAR (=midi + embedded lyric events)) where there are some
byte sequences that do not make sense to me.
(attaching a short hexdump at the end of mail).
Basically I read the MTrk shown below and after the
ff 01 TEXT meta event which contains the text 'Reset Volume'
there are sequences of 00 07 7f till the next ff 01 text event
'Reset Pan'.
...
8142 b1 0a 40
00 5b 40
00 07 00
85f810 ff 01 0c 52 65 73 65 74 20 56 6f 6c 75 6d 65 "Reset Volume"
00 07 7f
00 07 7f
00 07 7f
...
Apparently, the software that wrote this file thought it could use
running status, but as Pedro said, FF meta-events cancel running
status. This file clearly violates the SMF specification.
And there are exactly 16 "00 07 7f" commands, so I think the intention
was to reset all 16 channels (which isn't possible at all with running
status).
(There is a status byte for the pitch bends, but this one is
repeated with running status 15 times, too.)
HTH
Clemens