summaryrefslogtreecommitdiffstats
path: root/services/audioflinger/AudioFlinger.h
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2010-07-28 01:32:47 -0700
committerEric Laurent <elaurent@google.com>2010-07-29 02:34:40 -0700
commit39e94f8f723d445447fdee0822291e664b631f60 (patch)
tree99147be3db86a4bacc908e61498a9ada95ce725c /services/audioflinger/AudioFlinger.h
parent1b58c743e6748272e98cd04d3c0f63e371a44329 (diff)
downloadframeworks_av-39e94f8f723d445447fdee0822291e664b631f60.zip
frameworks_av-39e94f8f723d445447fdee0822291e664b631f60.tar.gz
frameworks_av-39e94f8f723d445447fdee0822291e664b631f60.tar.bz2
Allow creation of an audio effect on a session with no audio tracks.
This is necessary to allow creating and enabling an effect attached to a particular player session before the playback is started. As a matter of fact, the implementation of the mediaplayer does not create the AudioTrack before playback starts. Change-Id: I1266e8885f9d756acc949303321aaac0fbf83e34
Diffstat (limited to 'services/audioflinger/AudioFlinger.h')
-rw-r--r--services/audioflinger/AudioFlinger.h13
1 files changed, 11 insertions, 2 deletions
diff --git a/services/audioflinger/AudioFlinger.h b/services/audioflinger/AudioFlinger.h
index 8f667a3..5520551 100644
--- a/services/audioflinger/AudioFlinger.h
+++ b/services/audioflinger/AudioFlinger.h
@@ -613,7 +613,15 @@ private:
void disconnectEffect(const sp< EffectModule>& effect,
const wp<EffectHandle>& handle);
- bool hasAudioSession(int sessionId);
+ // return values for hasAudioSession (bit field)
+ enum effect_state {
+ EFFECT_SESSION = 0x1, // the audio session corresponds to at least one
+ // effect
+ TRACK_SESSION = 0x2 // the audio session corresponds to at least one
+ // track
+ };
+
+ uint32_t hasAudioSession(int sessionId);
sp<EffectChain> getEffectChain(int sessionId);
sp<EffectChain> getEffectChain_l(int sessionId);
status_t addEffectChain_l(const sp<EffectChain>& chain);
@@ -776,7 +784,8 @@ private:
int nextUniqueId();
status_t moveEffectChain_l(int session,
AudioFlinger::PlaybackThread *srcThread,
- AudioFlinger::PlaybackThread *dstThread);
+ AudioFlinger::PlaybackThread *dstThread,
+ bool reRegister);
friend class AudioBuffer;