summaryrefslogtreecommitdiffstats
path: root/services
diff options
context:
space:
mode:
authorGlenn Kasten <gkasten@google.com>2012-10-19 13:22:21 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2012-10-19 13:22:21 -0700
commitd3eb71055a81cf405ae3fac8172d3fd592ed2e4b (patch)
tree601c6f79a81d778c384af394fc9c45eaedbeabae /services
parent882863ff933605bc9376df0303bd13fd0e3d99e7 (diff)
parent10640a5d5041629433e1c4aa49e4d3281e408542 (diff)
downloadframeworks_av-d3eb71055a81cf405ae3fac8172d3fd592ed2e4b.zip
frameworks_av-d3eb71055a81cf405ae3fac8172d3fd592ed2e4b.tar.gz
frameworks_av-d3eb71055a81cf405ae3fac8172d3fd592ed2e4b.tar.bz2
am 424b4a57: am 291f824e: Remove active track when thread goes to standby
* commit '424b4a57f5e1e8bd99cb619398389a467ec41f92': Remove active track when thread goes to standby
Diffstat (limited to 'services')
-rw-r--r--services/audioflinger/AudioFlinger.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/services/audioflinger/AudioFlinger.cpp b/services/audioflinger/AudioFlinger.cpp
index 6a35053..76d6447 100644
--- a/services/audioflinger/AudioFlinger.cpp
+++ b/services/audioflinger/AudioFlinger.cpp
@@ -3033,7 +3033,7 @@ AudioFlinger::PlaybackThread::mixer_state AudioFlinger::MixerThread::prepareTrac
(mOutput->stream->get_latency(mOutput->stream)*mSampleRate) / 1000;
size_t framesWritten =
mBytesWritten / audio_stream_frame_size(&mOutput->stream->common);
- if (!track->presentationComplete(framesWritten, audioHALFrames)) {
+ if (!(mStandby || track->presentationComplete(framesWritten, audioHALFrames))) {
// track stays in active list until presentation is complete
break;
}
@@ -3278,7 +3278,7 @@ AudioFlinger::PlaybackThread::mixer_state AudioFlinger::MixerThread::prepareTrac
size_t audioHALFrames = (latency_l() * mSampleRate) / 1000;
size_t framesWritten =
mBytesWritten / audio_stream_frame_size(&mOutput->stream->common);
- if (track->presentationComplete(framesWritten, audioHALFrames)) {
+ if (mStandby || track->presentationComplete(framesWritten, audioHALFrames)) {
if (track->isStopped()) {
track->reset();
}
@@ -3801,7 +3801,7 @@ AudioFlinger::PlaybackThread::mixer_state AudioFlinger::DirectOutputThread::prep
size_t audioHALFrames = (latency_l() * mSampleRate) / 1000;
size_t framesWritten =
mBytesWritten / audio_stream_frame_size(&mOutput->stream->common);
- if (track->presentationComplete(framesWritten, audioHALFrames)) {
+ if (mStandby || track->presentationComplete(framesWritten, audioHALFrames)) {
if (track->isStopped()) {
track->reset();
}