OSDN Git Service

Fix issue 2115450: a2dp thread is started, even though we are only connected to heads...
authorEric Laurent <elaurent@google.com>
Mon, 14 Sep 2009 08:38:42 +0000 (01:38 -0700)
committerEric Laurent <elaurent@google.com>
Mon, 14 Sep 2009 09:37:15 +0000 (02:37 -0700)
commit64c0e1a51c3063991b4b01cefcf462a74a777592
tree269c73ac43e177f62125340f9937f09f61a84d3c
parent91e2d8651fe38a921b37a8bf8b3148c572cf9430
Fix issue 2115450: a2dp thread is started, even though we are only connected to headset and not playing music.

This is due to a regression introduced by change 24114: when no audio tracks are ready for mixing, 0s are written to audio hardware. However this should only happen if tracks have already been mixed since the audio flinger thread woke up.
Also do not write 0s to audio hardware in direct output threads when audio format is not linear PCM.
libs/audioflinger/AudioFlinger.cpp