Fixed regression in XMIDI parsing.
svn-id: r7706
This commit is contained in:
parent
b5e5403196
commit
46a0be5ae8
2 changed files with 18 additions and 2 deletions
|
@ -70,8 +70,8 @@ protected:
|
|||
|
||||
protected:
|
||||
static uint32 readVLQ (byte * &data);
|
||||
void resetTracking();
|
||||
void allNotesOff();
|
||||
virtual void resetTracking();
|
||||
virtual void allNotesOff();
|
||||
virtual void parseNextEvent (EventInfo &info) = 0;
|
||||
|
||||
// Multi-byte read helpers
|
||||
|
|
|
@ -46,6 +46,8 @@ protected:
|
|||
|
||||
protected:
|
||||
uint32 readVLQ2 (byte * &data);
|
||||
void allNotesOff();
|
||||
void resetTracking();
|
||||
void parseNextEvent (EventInfo &info);
|
||||
|
||||
public:
|
||||
|
@ -332,4 +334,18 @@ void MidiParser_XMIDI::unloadMusic() {
|
|||
_active_track = 255;
|
||||
}
|
||||
|
||||
void MidiParser_XMIDI::allNotesOff() {
|
||||
MidiParser::allNotesOff();
|
||||
|
||||
// Reset the list of active notes.
|
||||
int i;
|
||||
for (i = 0; i < ARRAYSIZE(_notes_cache); ++i)
|
||||
_notes_cache[i].off_time = 0;
|
||||
}
|
||||
|
||||
void MidiParser_XMIDI::resetTracking() {
|
||||
MidiParser::resetTracking();
|
||||
_inserted_delta = 0;
|
||||
}
|
||||
|
||||
MidiParser *MidiParser::createParser_XMIDI() { return new MidiParser_XMIDI; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue