diff options
author | SathishKumar Mani <smani@codeaurora.org> | 2012-01-17 10:49:47 -0800 |
---|---|---|
committer | Iliyan Malchev <malchev@google.com> | 2012-09-26 18:48:44 -0700 |
commit | 76b111685010e1fea7c0a865c038aee35507fde4 (patch) | |
tree | 25a9d24b4cc23476d25cc026ff0888a3ffcf73e8 /services/audioflinger/AudioResampler.cpp | |
parent | 12bff5dd87e6b863482e6bfd9f4561078ebcf3f0 (diff) | |
download | frameworks_av-76b111685010e1fea7c0a865c038aee35507fde4.zip frameworks_av-76b111685010e1fea7c0a865c038aee35507fde4.tar.gz frameworks_av-76b111685010e1fea7c0a865c038aee35507fde4.tar.bz2 |
audioflinger: use resample coefficients from audio-resampler library.
-Add a separate quality VERY_HIGH_QUALITY in resampler
-Use resample coefficients audio-resampler library for
quality VERY_HIGH_QUALITY.
-This improves the quality of resampled output.
Bug: 7024293
Change-Id: Ia44142413bed5f5963d7eab7846eec877a2415e4
Signed-off-by: Iliyan Malchev <malchev@google.com>
Diffstat (limited to 'services/audioflinger/AudioResampler.cpp')
-rw-r--r-- | services/audioflinger/AudioResampler.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/services/audioflinger/AudioResampler.cpp b/services/audioflinger/AudioResampler.cpp index fbb54cf..5c1c905 100644 --- a/services/audioflinger/AudioResampler.cpp +++ b/services/audioflinger/AudioResampler.cpp @@ -23,8 +23,8 @@ #include <cutils/log.h> #include <cutils/properties.h> #include "AudioResampler.h" -#if 0 #include "AudioResamplerSinc.h" +#if 0 #include "AudioResamplerCubic.h" #endif @@ -106,11 +106,14 @@ AudioResampler* AudioResampler::create(int bitDepth, int inChannelCount, ALOGV("Create cubic Resampler"); resampler = new AudioResamplerCubic(bitDepth, inChannelCount, sampleRate); break; +#endif case HIGH_QUALITY: - ALOGV("Create sinc Resampler"); + ALOGV("Create HIGH_QUALITY sinc Resampler"); resampler = new AudioResamplerSinc(bitDepth, inChannelCount, sampleRate); + case VERY_HIGH_QUALITY: + ALOGV("Create VERY_HIGH_QUALITY sinc Resampler = %d",quality); + resampler = new AudioResamplerSinc(bitDepth, inChannelCount, sampleRate, quality); break; -#endif } // initialize resampler |