summaryrefslogtreecommitdiffstats
path: root/services/audioflinger
diff options
context:
space:
mode:
authorRamjee Singh <ramjee@codeaurora.org>2015-02-02 20:09:35 +0530
committerGerrit Code Review <gerrit@cyanogenmod.org>2015-11-20 15:43:57 -0800
commit07f1086ff02439dc20f3bff6607be920630185e0 (patch)
treef83355f1a7ed5820d320665d7447ee987f67fb8a /services/audioflinger
parenteeb8a90192cee627890a74f75a0c64145fbc34f4 (diff)
downloadframeworks_av-07f1086ff02439dc20f3bff6607be920630185e0.zip
frameworks_av-07f1086ff02439dc20f3bff6607be920630185e0.tar.gz
frameworks_av-07f1086ff02439dc20f3bff6607be920630185e0.tar.bz2
audio: Set OutputFormat of AudioMixer to PCM16
- MixerThread sets OutputFormat to PCM_FLOAT by default We are having issue with SRS Effects due to this format - Fix is to select always PCM16 format as Audio HAL supports only PCM16 Change-Id: I26d23836180fe95b4c32b071593827b6fe4d674e
Diffstat (limited to 'services/audioflinger')
-rw-r--r--services/audioflinger/Threads.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/services/audioflinger/Threads.cpp b/services/audioflinger/Threads.cpp
index cdf8b1e..d70e457 100644
--- a/services/audioflinger/Threads.cpp
+++ b/services/audioflinger/Threads.cpp
@@ -3319,11 +3319,15 @@ AudioFlinger::MixerThread::MixerThread(const sp<AudioFlinger>& audioFlinger, Aud
}
if (initFastMixer) {
audio_format_t fastMixerFormat;
+#ifdef LEGACY_ALSA_AUDIO
+ fastMixerFormat = AUDIO_FORMAT_PCM_16_BIT;
+#else
if (mMixerBufferEnabled && mEffectBufferEnabled) {
fastMixerFormat = AUDIO_FORMAT_PCM_FLOAT;
} else {
fastMixerFormat = AUDIO_FORMAT_PCM_16_BIT;
}
+#endif
if (mFormat != fastMixerFormat) {
// change our Sink format to accept our intermediate precision
mFormat = fastMixerFormat;