Docs/MidiEvent.md
MidiEvent is the base class for all MIDI events in NAudio. It has the following properties:
MidiCommandCode indicating what type of MIDI event it is (e.g note on, note off)
NoteOn may actually be a note off message if its velocity is zeroNoteEvent is used to represent Note Off and Key After Touch messages. It is also the base class for NoteOnEvent.
It has the following properties
NoteOnEvent inherits from NoteEvent and adds a property to track the associated note off event. This makes it easier to adjust the duration of a note, as the duration is found by comparing absolute times of the note on and off events. It also makes sure the associated note off event stays updated if the note number or channel properties change.
MetaEvent is the base class for all MIDI meta events. The main property is MetaEventType which indicates which type of MIDI meta event it is. Most common meta event types have their own specialized class which are discussed next.
TextEvent is used for all meta events whose data is text. Examples include markers, copyright messages, lyrics, track names as well as basic text events. The Text property allows you to access the text in these events.
KeySignatureEvent exposes the raw SharpsFlats and MajorMinor properties.
The TempoEvent exposes both the raw MicrosecondsPerQuarterNote value from the MIDI event and also converts that into a Tempo expressed as beats per minute.
TimeSignatureEvent exposes Numerator (number of beats in a bar), Denominator (which is confusingly in 'beat units' so 1 means 2, 2 means 4 (crochet), 3 means 8 (quaver), 4 means 16 and 5 means 32), as well as TicksInMetronomeClick and No32ndNotesInQuarterNote.