diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2009-04-23 17:48:37 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2009-04-23 17:48:37 +0000 |
commit | 28368793415ba934132994d8c10a5e149c1a8d9d (patch) | |
tree | 818d5f406e0c9b6f95f43faae0ff88d885a59ad6 /libs/ardour/audio_track.cc | |
parent | 0a22716b74d52fcbef37bebf529048f7f3bc79e0 (diff) |
remove offset from process callback tree. some breakage may have occured. yes, really.
git-svn-id: svn://localhost/ardour2/branches/3.0@4999 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/audio_track.cc')
-rw-r--r-- | libs/ardour/audio_track.cc | 51 |
1 files changed, 25 insertions, 26 deletions
diff --git a/libs/ardour/audio_track.cc b/libs/ardour/audio_track.cc index 25161ea249..d814709798 100644 --- a/libs/ardour/audio_track.cc +++ b/libs/ardour/audio_track.cc @@ -453,7 +453,7 @@ AudioTrack::set_state_part_two () } int -AudioTrack::no_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, nframes_t offset, +AudioTrack::no_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, bool session_state_changing, bool can_record, bool rec_monitors_input) { if (n_outputs().n_total() == 0) { @@ -461,7 +461,7 @@ AudioTrack::no_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_fra } if (!_active) { - silence (nframes, offset); + silence (nframes); return 0; } @@ -469,7 +469,7 @@ AudioTrack::no_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_fra /* XXX is this safe to do against transport state changes? */ - passthru_silence (start_frame, end_frame, nframes, offset, 0, false); + passthru_silence (start_frame, end_frame, nframes, 0, false); return 0; } @@ -518,12 +518,12 @@ AudioTrack::no_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_fra */ if (_have_internal_generator) { - passthru_silence (start_frame, end_frame, nframes, offset, 0, true); + passthru_silence (start_frame, end_frame, nframes, 0, true); } else { if (_meter_point == MeterInput) { - just_meter_input (start_frame, end_frame, nframes, offset); + just_meter_input (start_frame, end_frame, nframes); } - passthru_silence (start_frame, end_frame, nframes, offset, 0, false); + passthru_silence (start_frame, end_frame, nframes, 0, false); } } else { @@ -531,14 +531,14 @@ AudioTrack::no_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_fra /* we're sending signal, but we may still want to meter the input. */ - passthru (start_frame, end_frame, nframes, offset, 0, (_meter_point == MeterInput)); + passthru (start_frame, end_frame, nframes, 0, (_meter_point == MeterInput)); } return 0; } int -AudioTrack::roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, nframes_t offset, int declick, +AudioTrack::roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, int declick, bool can_record, bool rec_monitors_input) { int dret; @@ -562,36 +562,35 @@ AudioTrack::roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, } if (!_active) { - silence (nframes, offset); + silence (nframes); return 0; } transport_frame = _session.transport_frame(); - prepare_inputs( nframes, offset ); + prepare_inputs (nframes); + + if ((nframes = check_initial_delay (nframes, transport_frame)) == 0) { - if ((nframes = check_initial_delay (nframes, offset, transport_frame)) == 0) { /* need to do this so that the diskstream sets its playback distance to zero, thus causing diskstream::commit to do nothing. */ - return diskstream->process (transport_frame, 0, 0, can_record, rec_monitors_input); + return diskstream->process (transport_frame, 0, can_record, rec_monitors_input); } _silent = false; apply_gain_automation = false; - if ((dret = diskstream->process (transport_frame, nframes, offset, can_record, rec_monitors_input)) != 0) { - - silence (nframes, offset); - + if ((dret = diskstream->process (transport_frame, nframes, can_record, rec_monitors_input)) != 0) { + silence (nframes); return dret; } /* special condition applies */ if (_meter_point == MeterInput) { - just_meter_input (start_frame, end_frame, nframes, offset); + just_meter_input (start_frame, end_frame, nframes); } if (diskstream->record_enabled() && !can_record && !Config->get_auto_input()) { @@ -600,7 +599,7 @@ AudioTrack::roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, at least potentially (depending on monitoring options) */ - passthru (start_frame, end_frame, nframes, offset, 0, true); + passthru (start_frame, end_frame, nframes, 0, true); } else if ((b = diskstream->playback_buffer(0)) != 0) { @@ -696,18 +695,18 @@ AudioTrack::roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, } } - process_output_buffers (bufs, start_frame, end_frame, nframes, offset, (!_session.get_record_enabled() || !Config->get_do_not_record_plugins()), declick, (_meter_point != MeterInput)); + process_output_buffers (bufs, start_frame, end_frame, nframes, (!_session.get_record_enabled() || !Config->get_do_not_record_plugins()), declick, (_meter_point != MeterInput)); } else { /* problem with the diskstream; just be quiet for a bit */ - silence (nframes, offset); + silence (nframes); } return 0; } int -AudioTrack::silent_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, nframes_t offset, +AudioTrack::silent_roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, bool can_record, bool rec_monitors_input) { if (n_outputs().n_total() == 0 && _processors.empty()) { @@ -715,16 +714,16 @@ AudioTrack::silent_roll (nframes_t nframes, nframes_t start_frame, nframes_t end } if (!_active) { - silence (nframes, offset); + silence (nframes); return 0; } _silent = true; apply_gain_automation = false; - silence (nframes, offset); + silence (nframes); - return audio_diskstream()->process (_session.transport_frame() + offset, nframes, offset, can_record, rec_monitors_input); + return audio_diskstream()->process (_session.transport_frame(), nframes, can_record, rec_monitors_input); } int @@ -781,7 +780,7 @@ AudioTrack::export_stuff (BufferSet& buffers, nframes_t start, nframes_t nframes if ((processor = boost::dynamic_pointer_cast<Processor>(*i)) != 0) { switch (processor->placement()) { case PreFader: - processor->run_in_place (buffers, start, start+nframes, nframes, 0); + processor->run_in_place (buffers, start, start+nframes, nframes); break; case PostFader: post_fader_work = true; @@ -821,7 +820,7 @@ AudioTrack::export_stuff (BufferSet& buffers, nframes_t start, nframes_t nframes case PreFader: break; case PostFader: - processor->run_in_place (buffers, start, start+nframes, nframes, 0); + processor->run_in_place (buffers, start, start+nframes, nframes); break; } } |