Remove unused rec_monitors_input variables.

git-svn-id: svn://localhost/ardour2/branches/3.0@10091 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
Carl Hetherington 2011-09-18 19:49:26 +00:00
parent e65636a087
commit 87d57a1de9
18 changed files with 42 additions and 59 deletions

View file

@ -171,7 +171,7 @@ class AudioDiskstream : public Diskstream
protected:
friend class AudioTrack;
int process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool rec_monitors_input, bool& need_butler);
int process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool& need_butler);
bool commit (framecnt_t nframes);
private:
@ -237,7 +237,7 @@ class AudioDiskstream : public Diskstream
framepos_t& start, framecnt_t cnt,
ChannelInfo* channel_info, int channel, bool reversed);
void finish_capture (bool rec_monitors_input, boost::shared_ptr<ChannelList>);
void finish_capture (boost::shared_ptr<ChannelList>);
void transport_stopped_wallclock (struct tm&, time_t, bool abort);
void transport_looped (framepos_t transport_frame);

View file

@ -40,7 +40,7 @@ class AudioTrack : public Track
bool can_use_mode (TrackMode m, bool& bounce_required);
int roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
int declick, bool can_record, bool rec_monitors_input, bool& need_butler);
int declick, bool can_record, bool& need_butler);
void use_new_diskstream ();
void set_diskstream (boost::shared_ptr<Diskstream>);

View file

@ -185,7 +185,7 @@ class Diskstream : public SessionObject, public PublicDiskstream
protected:
friend class Track;
virtual int process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool rec_monitors_input, bool& need_butler) = 0;
virtual int process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool& need_butler) = 0;
virtual bool commit (framecnt_t nframes) = 0;
//private:

View file

@ -74,10 +74,10 @@ public:
void main_thread();
int silent_process_routes (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
bool can_record, bool rec_monitors_input, bool& need_butler);
bool can_record, bool& need_butler);
int process_routes (pframes_t nframes, framepos_t start_frame, framepos_t end_frame, int declick,
bool can_record, bool rec_monitors_input, bool& need_butler);
bool can_record, bool& need_butler);
int routes_no_roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
bool non_rt_pending, bool can_record, int declick);
@ -131,7 +131,6 @@ private:
framepos_t _process_start_frame;
framepos_t _process_end_frame;
bool _process_can_record;
bool _process_rec_monitors_input;
bool _process_non_rt_pending;
int _process_declick;

View file

@ -142,7 +142,7 @@ class MidiDiskstream : public Diskstream
protected:
friend class MidiTrack;
int process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool rec_monitors_input, bool& need_butler);
int process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool& need_butler);
bool commit (framecnt_t nframes);
static framecnt_t midi_readahead;
@ -156,7 +156,7 @@ class MidiDiskstream : public Diskstream
int read (framepos_t& start, framecnt_t cnt, bool reversed);
void finish_capture (bool rec_monitors_input);
void finish_capture ();
void transport_stopped_wallclock (struct tm&, time_t, bool abort);
void transport_looped (framepos_t transport_frame);

View file

@ -42,7 +42,7 @@ public:
int init ();
int roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
int declick, bool can_record, bool rec_monitors_input, bool& need_butler);
int declick, bool can_record, bool& need_butler);
void realtime_handle_transport_stopped ();
void realtime_locate ();

View file

@ -109,13 +109,13 @@ class Route : public SessionObject, public Automatable, public RouteGroupMember,
/* these are the core of the API of a Route. see the protected sections as well */
virtual int roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
int declick, bool can_record, bool rec_monitors_input, bool& need_butler);
int declick, bool can_record, bool& need_butler);
virtual int no_roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
bool state_changing, bool can_record);
virtual int silent_roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
bool can_record, bool rec_monitors_input, bool& need_butler);
bool can_record, bool& need_butler);
virtual void toggle_monitor_input ();
virtual bool can_record() { return false; }

View file

@ -963,18 +963,6 @@ class Session : public PBD::StatefulDestructible, public PBD::ScopedConnectionLi
int process_routes (pframes_t, bool& need_butler);
int silent_process_routes (pframes_t, bool& need_butler);
bool get_rec_monitors_input () {
if (actively_recording()) {
return true;
} else {
if (config.get_auto_input()) {
return false;
} else {
return true;
}
}
}
int get_transport_declick_required () {
if (transport_sub_state & PendingDeclickIn) {
transport_sub_state &= ~PendingDeclickIn;

View file

@ -52,10 +52,10 @@ class Track : public Route, public PublicDiskstream
bool state_changing, bool can_record);
int silent_roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
bool can_record, bool rec_monitors_input, bool& need_butler);
bool can_record, bool& need_butler);
virtual int roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
int declick, bool can_record, bool rec_monitors_input, bool& need_butler) = 0;
int declick, bool can_record, bool& need_butler) = 0;
bool needs_butler() const { return _needs_butler; }
void toggle_monitor_input ();

View file

@ -405,7 +405,7 @@ AudioDiskstream::prepare_record_status(framepos_t capture_start_frame)
}
int
AudioDiskstream::process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool rec_monitors_input, bool& need_butler)
AudioDiskstream::process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool& need_butler)
{
uint32_t n;
boost::shared_ptr<ChannelList> c = channels.reader();
@ -520,7 +520,7 @@ AudioDiskstream::process (framepos_t transport_frame, pframes_t nframes, bool ca
} else {
if (was_recording) {
finish_capture (rec_monitors_input, c);
finish_capture (c);
}
}
@ -1349,7 +1349,7 @@ AudioDiskstream::transport_stopped_wallclock (struct tm& when, time_t twhen, boo
uint32_t n = 0;
bool mark_write_completed = false;
finish_capture (true, c);
finish_capture (c);
/* butler is already stopped, but there may be work to do
to flush remaining data to disk.
@ -1548,7 +1548,7 @@ AudioDiskstream::transport_looped (framepos_t transport_frame)
}
}
finish_capture (true, c);
finish_capture (c);
// the next region will start recording via the normal mechanism
// we'll set the start position to the current transport pos
@ -1581,7 +1581,7 @@ AudioDiskstream::transport_looped (framepos_t transport_frame)
}
void
AudioDiskstream::finish_capture (bool /*rec_monitors_input*/, boost::shared_ptr<ChannelList> c)
AudioDiskstream::finish_capture (boost::shared_ptr<ChannelList> c)
{
was_recording = false;
first_recordable_frame = max_framepos;

View file

@ -354,7 +354,7 @@ AudioTrack::set_state_part_two ()
int
AudioTrack::roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame, int declick,
bool can_record, bool rec_monitors_input, bool& need_butler)
bool can_record, bool& need_butler)
{
Glib::RWLock::ReaderLock lm (_processor_lock, Glib::TRY_LOCK);
if (!lm.locked()) {
@ -386,13 +386,13 @@ AudioTrack::roll (pframes_t nframes, framepos_t start_frame, framepos_t end_fram
playback distance to zero, thus causing diskstream::commit
to do nothing.
*/
return diskstream->process (transport_frame, 0, can_record, rec_monitors_input, need_butler);
return diskstream->process (transport_frame, 0, can_record, need_butler);
}
_silent = false;
_amp->apply_gain_automation(false);
if ((dret = diskstream->process (transport_frame, nframes, can_record, rec_monitors_input, need_butler)) != 0) {
if ((dret = diskstream->process (transport_frame, nframes, can_record, need_butler)) != 0) {
silence (nframes);
return dret;
}

View file

@ -223,7 +223,7 @@ Auditioner::play_audition (framecnt_t nframes)
this_nframes = min (nframes, length - current_frame);
if ((ret = roll (this_nframes, current_frame, current_frame + nframes, false, false, false, need_butler)) != 0) {
if ((ret = roll (this_nframes, current_frame, current_frame + nframes, false, false, need_butler)) != 0) {
silence (nframes);
return ret;
}

View file

@ -513,13 +513,12 @@ Graph::dump (int chain)
int
Graph::silent_process_routes (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
bool can_record, bool rec_monitors_input, bool& need_butler)
bool can_record, bool& need_butler)
{
_process_nframes = nframes;
_process_start_frame = start_frame;
_process_end_frame = end_frame;
_process_can_record = can_record;
_process_rec_monitors_input = rec_monitors_input;
_process_silent = true;
_process_noroll = false;
@ -539,7 +538,7 @@ Graph::silent_process_routes (pframes_t nframes, framepos_t start_frame, framepo
int
Graph::process_routes (pframes_t nframes, framepos_t start_frame, framepos_t end_frame, int declick,
bool can_record, bool rec_monitors_input, bool& need_butler)
bool can_record, bool& need_butler)
{
DEBUG_TRACE (DEBUG::ProcessThreads, string_compose ("graph execution from %1 to %2 = %3\n", start_frame, end_frame, nframes));
@ -547,7 +546,6 @@ Graph::process_routes (pframes_t nframes, framepos_t start_frame, framepos_t end
_process_start_frame = start_frame;
_process_end_frame = end_frame;
_process_can_record = can_record;
_process_rec_monitors_input = rec_monitors_input;
_process_declick = declick;
_process_silent = false;
@ -601,13 +599,13 @@ Graph::process_one_route (Route* route)
DEBUG_TRACE (DEBUG::ProcessThreads, string_compose ("%1 runs route %2\n", pthread_self(), route->name()));
if (_process_silent) {
retval = route->silent_roll (_process_nframes, _process_start_frame, _process_end_frame, _process_can_record, _process_rec_monitors_input, need_butler);
retval = route->silent_roll (_process_nframes, _process_start_frame, _process_end_frame, _process_can_record, need_butler);
} else if (_process_noroll) {
route->set_pending_declick (_process_declick);
retval = route->no_roll (_process_nframes, _process_start_frame, _process_end_frame, _process_non_rt_pending, _process_can_record);
} else {
route->set_pending_declick (_process_declick);
retval = route->roll (_process_nframes, _process_start_frame, _process_end_frame, _process_declick, _process_can_record, _process_rec_monitors_input, need_butler);
retval = route->roll (_process_nframes, _process_start_frame, _process_end_frame, _process_declick, _process_can_record, need_butler);
}
if (retval) {

View file

@ -475,7 +475,7 @@ trace_midi (ostream& o, MIDI::byte *msg, size_t len)
#endif
int
MidiDiskstream::process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool rec_monitors_input, bool& need_butler)
MidiDiskstream::process (framepos_t transport_frame, pframes_t nframes, bool can_record, bool& need_butler)
{
int ret = -1;
framecnt_t rec_offset = 0;
@ -563,7 +563,7 @@ MidiDiskstream::process (framepos_t transport_frame, pframes_t nframes, bool can
} else {
if (was_recording) {
finish_capture (rec_monitors_input);
finish_capture ();
}
}
@ -923,7 +923,7 @@ MidiDiskstream::transport_stopped_wallclock (struct tm& /*when*/, time_t /*twhen
MidiRegion::SourceList::iterator src;
vector<CaptureInfo*>::iterator ci;
finish_capture (true);
finish_capture ();
/* butler is already stopped, but there may be work to do
to flush remaining data to disk.
@ -1124,7 +1124,7 @@ MidiDiskstream::transport_looped (framepos_t transport_frame)
}
}
finish_capture (true);
finish_capture ();
// the next region will start recording via the normal mechanism
// we'll set the start position to the current transport pos
@ -1137,7 +1137,7 @@ MidiDiskstream::transport_looped (framepos_t transport_frame)
}
void
MidiDiskstream::finish_capture (bool /*rec_monitors_input*/)
MidiDiskstream::finish_capture ()
{
was_recording = false;

View file

@ -311,7 +311,7 @@ MidiTrack::set_state_part_two ()
int
MidiTrack::roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame, int declick,
bool can_record, bool rec_monitors_input, bool& needs_butler)
bool can_record, bool& needs_butler)
{
Glib::RWLock::ReaderLock lm (_processor_lock, Glib::TRY_LOCK);
if (!lm.locked()) {
@ -339,12 +339,12 @@ MidiTrack::roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame
playback distance to zero, thus causing diskstream::commit
to do nothing.
*/
return diskstream->process (transport_frame, 0, can_record, rec_monitors_input, needs_butler);
return diskstream->process (transport_frame, 0, can_record, needs_butler);
}
_silent = false;
if ((dret = diskstream->process (transport_frame, nframes, can_record, rec_monitors_input, needs_butler)) != 0) {
if ((dret = diskstream->process (transport_frame, nframes, can_record, needs_butler)) != 0) {
silence (nframes);
return dret;
}

View file

@ -2837,7 +2837,7 @@ Route::check_initial_delay (framecnt_t nframes, framecnt_t& transport_frame)
int
Route::roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame, int declick,
bool /*can_record*/, bool /*rec_monitors_input*/, bool& /* need_butler */)
bool /*can_record*/, bool& /* need_butler */)
{
Glib::RWLock::ReaderLock lm (_processor_lock, Glib::TRY_LOCK);
if (!lm.locked()) {
@ -2870,7 +2870,7 @@ Route::roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame, in
int
Route::silent_roll (pframes_t nframes, framepos_t /*start_frame*/, framepos_t /*end_frame*/,
bool /*can_record*/, bool /*rec_monitors_input*/, bool& /* need_butler */)
bool /*can_record*/, bool& /* need_butler */)
{
silence (nframes);
return 0;

View file

@ -136,7 +136,6 @@ Session::process_routes (pframes_t nframes, bool& need_butler)
{
bool record_active;
int declick = get_transport_declick_required();
bool rec_monitors = get_rec_monitors_input();
boost::shared_ptr<RouteList> r = routes.reader ();
if (transport_sub_state & StopPendingCapture) {
@ -155,7 +154,7 @@ Session::process_routes (pframes_t nframes, bool& need_butler)
*/
if (1 || route_graph->threads_in_use() > 0) {
DEBUG_TRACE(DEBUG::ProcessThreads,"calling graph/process-routes\n");
route_graph->process_routes( nframes, start_frame, end_frame, declick, record_active, rec_monitors, need_butler);
route_graph->process_routes (nframes, start_frame, end_frame, declick, record_active, need_butler);
} else {
for (RouteList::iterator i = r->begin(); i != r->end(); ++i) {
@ -168,7 +167,7 @@ Session::process_routes (pframes_t nframes, bool& need_butler)
(*i)->set_pending_declick (declick);
if ((ret = (*i)->roll (nframes, start_frame, end_frame, declick, record_active, rec_monitors, need_butler)) < 0) {
if ((ret = (*i)->roll (nframes, start_frame, end_frame, declick, record_active, need_butler)) < 0) {
stop_transport ();
return -1;
}
@ -182,7 +181,6 @@ int
Session::silent_process_routes (pframes_t nframes, bool& need_butler)
{
bool record_active = actively_recording();
bool rec_monitors = get_rec_monitors_input();
boost::shared_ptr<RouteList> r = routes.reader ();
const framepos_t start_frame = _transport_frame;
@ -193,7 +191,7 @@ Session::silent_process_routes (pframes_t nframes, bool& need_butler)
tracks, the graph never gets updated.
*/
if (1 || route_graph->threads_in_use() > 0) {
route_graph->silent_process_routes( nframes, start_frame, end_frame, record_active, rec_monitors, need_butler);
route_graph->silent_process_routes (nframes, start_frame, end_frame, record_active, need_butler);
} else {
for (RouteList::iterator i = r->begin(); i != r->end(); ++i) {
@ -203,7 +201,7 @@ Session::silent_process_routes (pframes_t nframes, bool& need_butler)
continue;
}
if ((ret = (*i)->silent_roll (nframes, start_frame, end_frame, record_active, rec_monitors, need_butler)) < 0) {
if ((ret = (*i)->silent_roll (nframes, start_frame, end_frame, record_active, need_butler)) < 0) {
stop_transport ();
return -1;
}

View file

@ -285,7 +285,7 @@ Track::no_roll (pframes_t nframes, framepos_t start_frame, framepos_t end_frame,
int
Track::silent_roll (pframes_t nframes, framepos_t /*start_frame*/, framepos_t /*end_frame*/,
bool can_record, bool rec_monitors_input, bool& need_butler)
bool can_record, bool& need_butler)
{
Glib::RWLock::ReaderLock lm (_processor_lock, Glib::TRY_LOCK);
if (!lm.locked()) {
@ -306,7 +306,7 @@ Track::silent_roll (pframes_t nframes, framepos_t /*start_frame*/, framepos_t /*
silence (nframes);
return _diskstream->process (_session.transport_frame(), nframes, can_record, rec_monitors_input, need_butler);
return _diskstream->process (_session.transport_frame(), nframes, can_record, need_butler);
}
void