OSDN Git Service

audioflinger: fix auxiliary effect attachment
authorEric Laurent <elaurent@google.com>
Fri, 29 Jun 2012 23:36:52 +0000 (16:36 -0700)
committerEric Laurent <elaurent@google.com>
Sat, 30 Jun 2012 00:03:53 +0000 (17:03 -0700)
commit717e128691f083a9469a1d0e363ac6ecd5c65d58
tree70761520a17703d543262ebe7778f51a360d7923
parent33e28dd3c033641f4db9d1b99c7c88d6d08c61f7
audioflinger: fix auxiliary effect attachment

Auxiliary effects (Reverb) are global effects and as such follow
the default rule which is to attach them to the output thread that
handles music streams by default. This causes a problem when several
threads are eligible to handle music streams as tracks can be attached
to either thread based on criteria unknown when teh effect is created.

The fix consists in moving the auxiliary effect if necessary when an
AudioTrack is attached to it and this track is not on the same
output thread.

Bug 6608561.

Change-Id: Ib32c3cabc731b2046aba728be1771982999c6069
services/audioflinger/AudioFlinger.cpp
services/audioflinger/AudioFlinger.h