diff options
-rw-r--r-- | muse/muse/audiooutput.cpp | 7 | ||||
-rw-r--r-- | muse/muse/audiotrack.cpp | 6 |
2 files changed, 7 insertions, 6 deletions
diff --git a/muse/muse/audiooutput.cpp b/muse/muse/audiooutput.cpp index dbf61af9..26af8fd8 100644 --- a/muse/muse/audiooutput.cpp +++ b/muse/muse/audiooutput.cpp @@ -150,7 +150,7 @@ void AudioOutput::stopRecording(const Pos& /*s*/, const Pos& /*e*/) //--------------------------------------------------------- // process -// synthesize "n" frames at buffer offset "offset" +// synthesize segmentSize frames at buffer offset "offset" // current frame position is "pos" //--------------------------------------------------------- @@ -161,6 +161,11 @@ void AudioOutput::process() AudioTrack::process(); + if (bufferEmpty) { + for (int c = 0; c < channels(); ++c) + memset(buffer[c], 0, sizeof(float) * segmentSize); + } + int n = segmentSize; if (audio->isRecording() && recordFlag() && _recFile) { // bounce to file diff --git a/muse/muse/audiotrack.cpp b/muse/muse/audiotrack.cpp index 62fde5ca..1639a19a 100644 --- a/muse/muse/audiotrack.cpp +++ b/muse/muse/audiotrack.cpp @@ -574,12 +574,8 @@ void AudioTrack::collectInputData() for (iRoute ir = rl->begin(); ir != rl->end(); ++ir) { float** ptr; int ch; - if (ir->type == Route::TRACK /*|| ir->type == Route::SYNTIPORT*/) { + if (ir->type == Route::TRACK) { AudioTrack* track = (AudioTrack*)ir->track; -//printf("collectInputData <%s><%s> channel %d off %d\n", -// track->name().toLatin1().data(), -// name().toLatin1().data(), -// track->channels(), track->off()); if (track->off() || song->bounceTrack == track) continue; ptr = track->buffer; |