add MIDITrack specific ::monitoring_state() method
git-svn-id: svn://localhost/ardour2/branches/3.0@11207 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
d0d6a2015f
commit
34373c30f3
|
@ -108,6 +108,7 @@ public:
|
|||
boost::shared_ptr<MidiBuffer> get_gui_feed_buffer () const;
|
||||
|
||||
void set_monitoring (MonitorChoice);
|
||||
MonitorState monitoring_state () const;
|
||||
|
||||
void set_input_active (bool);
|
||||
bool input_active () const;
|
||||
|
|
|
@ -748,3 +748,29 @@ MidiTrack::set_monitoring (MonitorChoice mc)
|
|||
md->reset_tracker ();
|
||||
}
|
||||
}
|
||||
|
||||
MonitorState
|
||||
MidiTrack::monitoring_state () const
|
||||
{
|
||||
/* Explicit requests */
|
||||
|
||||
if (_monitoring & MonitorInput) {
|
||||
return MonitoringInput;
|
||||
}
|
||||
|
||||
if (_monitoring & MonitorDisk) {
|
||||
return MonitoringDisk;
|
||||
}
|
||||
|
||||
if (_session.transport_rolling()) {
|
||||
return MonitoringDisk;
|
||||
}
|
||||
|
||||
/* the return value here doesn't mean that we're actually monitoring
|
||||
* input, let alone input *audio*. but it means that we are NOT
|
||||
* monitoring silence. this allows us to still hear any audio generated
|
||||
* by using internal generation techniques
|
||||
*/
|
||||
|
||||
return MonitoringInput;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user