diff options
author | Eric Laurent <elaurent@google.com> | 2014-09-29 09:43:03 -0700 |
---|---|---|
committer | Eric Laurent <elaurent@google.com> | 2014-09-29 17:40:36 -0700 |
commit | c260784e37dea73a2090d4ccd91472d61d3b6230 (patch) | |
tree | 2f6ffba5fe828dc4143db34e7b05b98f27d52567 /services | |
parent | dc2e6ddc933e40632e79a866d9ece870db1a975e (diff) | |
download | frameworks_av-c260784e37dea73a2090d4ccd91472d61d3b6230.zip frameworks_av-c260784e37dea73a2090d4ccd91472d61d3b6230.tar.gz frameworks_av-c260784e37dea73a2090d4ccd91472d61d3b6230.tar.bz2 |
audio policy: fix HW A/V sync output selection
commit b732cf5a broke the selection mechanism for the
HW A/V sync direct output.
Add a rule to only select a mixed output for basic PCM
stereo content when a direct output is not explicitly requested.
Bug: 17702382.
Change-Id: I1387690ace77cd4d6a8faf0b525c3d1008fba3f1
Diffstat (limited to 'services')
-rw-r--r-- | services/audiopolicy/AudioPolicyManager.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/services/audiopolicy/AudioPolicyManager.cpp b/services/audiopolicy/AudioPolicyManager.cpp index d0b990f..536987a 100644 --- a/services/audiopolicy/AudioPolicyManager.cpp +++ b/services/audiopolicy/AudioPolicyManager.cpp @@ -930,7 +930,9 @@ audio_io_handle_t AudioPolicyManager::getOutputForDevice( sp<IOProfile> profile; // skip direct output selection if the request can obviously be attached to a mixed output - if (audio_is_linear_pcm(format) && samplingRate <= MAX_MIXER_SAMPLING_RATE && + // and not explicitly requested + if (((flags & AUDIO_OUTPUT_FLAG_DIRECT) == 0) && + audio_is_linear_pcm(format) && samplingRate <= MAX_MIXER_SAMPLING_RATE && audio_channel_count_from_out_mask(channelMask) <= 2) { goto non_direct_output; } |