enable and extend EVORAL_MIDI_XML. Useful for Debugging. Any objections?
git-svn-id: svn://localhost/ardour2/branches/3.0@13223 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
@@ -71,8 +71,29 @@ MIDIEvent<Time>::to_xml() const
|
||||
result->add_property("Number", long(pgm_number()));
|
||||
break;
|
||||
|
||||
case MIDI_CMD_NOTE_ON:
|
||||
result = new XMLNode("NoteOn");
|
||||
result->add_property("Channel", long(channel()));
|
||||
result->add_property("Note", long(note()));
|
||||
result->add_property("Velocity", long(velocity()));
|
||||
break;
|
||||
|
||||
case MIDI_CMD_NOTE_OFF:
|
||||
result = new XMLNode("NoteOff");
|
||||
result->add_property("Channel", long(channel()));
|
||||
result->add_property("Note", long(note()));
|
||||
result->add_property("Velocity", long(velocity()));
|
||||
break;
|
||||
|
||||
case MIDI_CMD_BENDER:
|
||||
result = new XMLNode("PitchBendChange");
|
||||
result->add_property("Channel", long(channel()));
|
||||
result->add_property("Value", long(pitch_bender_value()));
|
||||
break;
|
||||
|
||||
default:
|
||||
// The implementation is continued as needed
|
||||
result = new XMLNode("NotImplemented");
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -82,6 +103,7 @@ MIDIEvent<Time>::to_xml() const
|
||||
#endif // EVORAL_MIDI_XML
|
||||
|
||||
template class MIDIEvent<Evoral::MusicalTime>;
|
||||
template class MIDIEvent<long long>;
|
||||
|
||||
} // namespace Evoral
|
||||
|
||||
|
||||
Reference in New Issue
Block a user