Commit Graph

8 Commits

Author SHA1 Message Date
Eric Laurent
101e77a31b Fix issue 2416481: Support Voice Dialer over BT SCO.
- AudioPolicyManager: allow platform specific choice for opening a direct output.
 Also fixed problems in direct output management.
- AudioFliinger: use shorter standby delay and track inactivity grace period for direct output
thread to free hardware resources as soon as possible.
- AudioSystem: do not use cached output selection in getOutput() when a direct output
can be selected.

Change-Id: If44b50d29237b8402ffd7a5ba1dc43c56f903e9b
2010-03-16 17:32:18 -07:00
Jean-Michel Trivi
08abf1fa13 Fix bug 2203203 Route STREAM_VOICE_CALL to A2DP when not in call.
Change-Id: I5581702780308658415dc4ad19fbe409fdc5c368
2010-03-14 10:55:57 -07:00
Jean-Michel Trivi
84cf7d9e88 Fix bug 2329540
Part 1 of the fix: when the user doesn't elect to use the car dock
 for music and media, the APM was not aware of the device being
 docked.
 This is fixed by dissociating the notification for the APM of
 the docking to the dock from the sink state change of the A2DP
 device.
 Also missing was forcing the volumes to be reevaluated whenever
 the device is docked or undocked, as volumes for docks may
 differ, even when the same output device is being used.

Change-Id: If5314e27821a71adbd6df6fdf887c45208241d96
2010-03-09 12:45:55 -08:00
Eric Laurent
219795f5d0 Fix issue 2317760: Change the priority between wired headset and A2DP.
Modified audio policy manager so that wired headset has precedence over A2DP headset.
2010-03-08 06:50:44 -08:00
Eric Laurent
15498d6a23 Fix issue 2327064: Music played via line out is interrupted due to the phone call audio on BT hs.
This is not a real fix for the issue but a change to make sure that the behavior is consistent regardless of
external condidions (WIFI ON or OFF, music started before call or not, A2DP device same as SCO device...).

As there is now way to guaranty good quality audio over both SCO and A2DP simultaneously, especially when WIFI is on, We will stick to this behavior:
When music is playing and we are docked to the desk dock and a call is answered with a BT SCO headset, A2DP output will be suspended.
If music is restarted during the call, it will appear muted to the user until the call is terminated.
2010-02-24 11:54:32 -08:00
Eric Laurent
34248170a7 Fix issue 2305382: Pick up original call makes a noisy beep when wired headset connected.
The noise is the residual ring tone that is still playing while the call is answered and the
audio route changed to headset or earpiece.

The fix consists in muting the ringing tone when changing mode from ringtone to in call
and delaying the route change until the audio buffers are emptied.
2010-02-23 11:00:56 -08:00
Eric Laurent
7ccc09a4f3 Remove verbose log from AudioPolicyManagerBase. 2010-01-28 13:42:59 -08:00
Eric Laurent
da3529b468 Create base class for audio policy manager.
First implementations of audio policy manager in Eclair branch have shown that most code is common to all platforms.
Creating AudioPolicyManagerBase base class will improve code maintainability and readability.

Audio policy manager code for platforms using generic audio previously in AudioPolicyManagerGeneric is replaced by AudioPolicyManagerBase.
Audio policy manager test code previously in AudioPolicyManagerGeneric is moved to AudioPolicyManagerBase.

Also added a wake lock for delayed commands in AudioPolicyService.
2010-01-13 09:25:13 -08:00