summaryrefslogtreecommitdiff
path: root/services
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2012-05-11 19:44:09 -0700
committerEric Laurent <elaurent@google.com>2012-05-12 10:21:08 -0700
commit808e7d16504cbe5b28bb88c31afb2542ab488965 (patch)
tree599b15f2754300fe2bcb5e0d6630220f45fb960f /services
parentbb9d731bc2b5759f72f6d382834e431a0389cf07 (diff)
AudioFlinger: fix global effects suspend logic
Audio effects on the output mix should not be suspended when effects on the output stage (post processing) are enabled. Change-Id: I2e1c08fa9358ea3cbaec68856738d504b1be54e4
Diffstat (limited to 'services')
-rw-r--r--services/audioflinger/AudioFlinger.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/services/audioflinger/AudioFlinger.cpp b/services/audioflinger/AudioFlinger.cpp
index 56a9942e..77b2bc8e 100644
--- a/services/audioflinger/AudioFlinger.cpp
+++ b/services/audioflinger/AudioFlinger.cpp
@@ -1465,7 +1465,9 @@ void AudioFlinger::ThreadBase::checkSuspendOnEffectEnabled_l(const sp<EffectModu
// suspend all effects in AUDIO_SESSION_OUTPUT_MIX when enabling any effect on
// another session. This gives the priority to well behaved effect control panels
// and applications not using global effects.
- if (sessionId != AUDIO_SESSION_OUTPUT_MIX) {
+ // Enabling post processing in AUDIO_SESSION_OUTPUT_STAGE session does not affect
+ // global effects
+ if ((sessionId != AUDIO_SESSION_OUTPUT_MIX) && (sessionId != AUDIO_SESSION_OUTPUT_STAGE)) {
setEffectSuspended_l(NULL, enabled, AUDIO_SESSION_OUTPUT_MIX);
}
}