summaryrefslogtreecommitdiff
path: root/libs/ardour/ardour/midi_track.h
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2015-03-26 00:47:34 -0400
committerDavid Robillard <d@drobilla.net>2015-03-26 00:47:34 -0400
commit7e2c8ace4bf30ce8e27f1089370d63d7ef604cfa (patch)
treefe6812cf1b5abc337db5a2395fe1945881c32f7c /libs/ardour/ardour/midi_track.h
parenta53bd7269797969bfb182a4caebc9361cac45795 (diff)
Follow MIDI control values with automation faders.
Fixes bug #6166 (except record). This attempts to follow the "current" control value somewhat aggressively: * On locate, slider is set to the value from the top region at the new transport position. * Playback or MIDI input is followed "live". * Whenever the slider is moved (including automatically), that value is emitted as an immediate event to keep external gear in sync. General idea is that the Ardour slider should act as a mirror of an external hardware knob, and both should be synced to whatever the control is at the current transport position. Since we lack real playback/touch/etc modes for these for now, we must choose one behaviour, and this seems like the most reasonable one. Follow is handled in the audio thread, which is probably not ideal, but since these controls have no lists and do not record, should be fine. Probably.
Diffstat (limited to 'libs/ardour/ardour/midi_track.h')
-rw-r--r--libs/ardour/ardour/midi_track.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/libs/ardour/ardour/midi_track.h b/libs/ardour/ardour/midi_track.h
index 2af5b4cf87..a12a0c6087 100644
--- a/libs/ardour/ardour/midi_track.h
+++ b/libs/ardour/ardour/midi_track.h
@@ -47,6 +47,7 @@ public:
void realtime_handle_transport_stopped ();
void realtime_locate ();
+ void non_realtime_locate (framepos_t);
boost::shared_ptr<Diskstream> create_diskstream ();
void set_diskstream (boost::shared_ptr<Diskstream>);
@@ -183,6 +184,9 @@ private:
void track_input_active (IOChange, void*);
void map_input_active (bool);
+ /** Update automation controls to reflect any changes in buffers. */
+ void update_controls (const BufferSet& bufs);
+
void filter_channels (BufferSet& bufs, ChannelMode mode, uint32_t mask);
/* if mode is ForceChannel, force mask to the lowest set channel or 1 if no