diff options
author | David Robillard <d@drobilla.net> | 2007-05-10 03:50:17 +0000 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2007-05-10 03:50:17 +0000 |
commit | 9a4a9cbb63958484553ed981822ca97ceb1dc4f5 (patch) | |
tree | 6888079450c5ba74d195732fafc99de8d8531c36 /libs/ardour/audio_track.cc | |
parent | 2a52135c663e9a60b5f0cc9cc6673799c3ea5549 (diff) |
Added nicer looking wrapper methods for ChanCount::get(DataType), sedified code to use it.
git-svn-id: svn://localhost/ardour2/trunk@1816 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/audio_track.cc')
-rw-r--r-- | libs/ardour/audio_track.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libs/ardour/audio_track.cc b/libs/ardour/audio_track.cc index 7274082e8e..7a0a8592ef 100644 --- a/libs/ardour/audio_track.cc +++ b/libs/ardour/audio_track.cc @@ -579,7 +579,7 @@ AudioTrack::roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, /* copy the diskstream data to all output buffers */ - const size_t limit = n_process_buffers().get(DataType::AUDIO); + const size_t limit = n_process_buffers().n_audio(); BufferSet& bufs = _session.get_scratch_buffers (n_process_buffers()); uint32_t n; @@ -587,7 +587,7 @@ AudioTrack::roll (nframes_t nframes, nframes_t start_frame, nframes_t end_frame, for (i = 0, n = 1; i < limit; ++i, ++n) { memcpy (bufs.get_audio(i).data(), b, sizeof (Sample) * nframes); - if (n < diskstream->n_channels().get(DataType::AUDIO)) { + if (n < diskstream->n_channels().n_audio()) { tmpb = diskstream->playback_buffer(n); if (tmpb!=0) { b = tmpb; @@ -657,13 +657,13 @@ AudioTrack::export_stuff (BufferSet& buffers, nframes_t start, nframes_t nframes return -1; } - assert(buffers.count().get(DataType::AUDIO) >= 1); + assert(buffers.count().n_audio() >= 1); uint32_t n=1; Sample* b = buffers.get_audio(0).data(); BufferSet::audio_iterator bi = buffers.audio_begin(); ++bi; for ( ; bi != buffers.audio_end(); ++bi, ++n) { - if (n < diskstream->n_channels().get(DataType::AUDIO)) { + if (n < diskstream->n_channels().n_audio()) { if (apl->read (bi->data(), mix_buffer, gain_buffer, start, nframes, n) != nframes) { return -1; } |