summaryrefslogtreecommitdiff
path: root/libs/ardour/ardour/types.h
diff options
context:
space:
mode:
Diffstat (limited to 'libs/ardour/ardour/types.h')
-rw-r--r--libs/ardour/ardour/types.h15
1 files changed, 13 insertions, 2 deletions
diff --git a/libs/ardour/ardour/types.h b/libs/ardour/ardour/types.h
index 3dc4ae2693..d5f10410db 100644
--- a/libs/ardour/ardour/types.h
+++ b/libs/ardour/ardour/types.h
@@ -61,8 +61,19 @@ namespace ARDOUR {
typedef unsigned char Byte;
- struct MidiEvent : public jack_midi_event_t {
- MidiEvent() { time = 0; size = 0; buffer = NULL; }
+ /** Identical to jack_midi_event_t, but with double timestamp
+ *
+ * time is either a frame time (from/to Jack) or a beat time (internal
+ * tempo time, used in MidiModel) depending on context.
+ */
+ struct MidiEvent {
+ MidiEvent(double t=0, size_t s=0, Byte* b=NULL)
+ : time(t), size(s), buffer(b)
+ {}
+
+ double time; /**< Sample index (or beat time) at which event is valid */
+ size_t size; /**< Number of bytes of data in \a buffer */
+ Byte* buffer; /**< Raw MIDI data */
};
enum IOChange {