summaryrefslogtreecommitdiffstats
path: root/services/audiopolicy/AudioPolicyManager.h
diff options
context:
space:
mode:
authorEric Laurent <elaurent@google.com>2014-12-10 11:21:49 -0800
committerJean-Michel Trivi <jmtrivi@google.com>2014-12-10 20:03:41 -0800
commitc722f30eef03e77054395ae122470cf8dba93937 (patch)
treedd70514cd24a44a12dfb43f0123b1e6255a70e57 /services/audiopolicy/AudioPolicyManager.h
parent7e45789f5fbcbe68075f57b6d17f72b7b48df546 (diff)
downloadframeworks_av-c722f30eef03e77054395ae122470cf8dba93937.zip
frameworks_av-c722f30eef03e77054395ae122470cf8dba93937.tar.gz
frameworks_av-c722f30eef03e77054395ae122470cf8dba93937.tar.bz2
audio policy: suppport for dynamic source
Completed support for dynamic sources: - remote submix input device is dynamically connected/disconnected when corresponding AudioTrack starts/stops. Also do not create a duplicated output for mixes used by dynamic policies. Bug: 16006090. Change-Id: Ib5b5a2159fcac9d9f410a5a2f1c64d7ebad79f72
Diffstat (limited to 'services/audiopolicy/AudioPolicyManager.h')
-rw-r--r--services/audiopolicy/AudioPolicyManager.h9
1 files changed, 4 insertions, 5 deletions
diff --git a/services/audiopolicy/AudioPolicyManager.h b/services/audiopolicy/AudioPolicyManager.h
index 3eef8fe..9ec3557 100644
--- a/services/audiopolicy/AudioPolicyManager.h
+++ b/services/audiopolicy/AudioPolicyManager.h
@@ -497,7 +497,7 @@ protected:
uint32_t mLatency; //
audio_output_flags_t mFlags; //
audio_devices_t mDevice; // current device this output is routed to
- String8 mPolicyMixAddress; // non empty or "0" when used by a dynamic policy
+ AudioMix *mPolicyMix; // non NULL when used by a dynamic policy
audio_patch_handle_t mPatchHandle;
uint32_t mRefCount[AUDIO_STREAM_CNT]; // number of streams of each type using this output
nsecs_t mStopTime[AUDIO_STREAM_CNT];
@@ -523,6 +523,7 @@ protected:
audio_port_handle_t mId;
audio_io_handle_t mIoHandle; // input handle
audio_devices_t mDevice; // current device this input is routed to
+ AudioMix *mPolicyMix; // non NULL when used by a dynamic policy
audio_patch_handle_t mPatchHandle;
uint32_t mRefCount; // number of AudioRecord clients using
// this input
@@ -530,9 +531,7 @@ protected:
audio_source_t mInputSource; // input source selected by application
//(mediarecorder.h)
const sp<IOProfile> mProfile; // I/O profile this output derives from
- // audio sessions attached to this input and the
- // corresponding device address
- DefaultKeyedVector<audio_session_t, String8> mSessions;
+ SortedVector<audio_session_t> mSessions; // audio sessions attached to this input
bool mIsSoundTrigger; // used by a soundtrigger capture
virtual void toAudioPortConfig(struct audio_port_config *dstConfig,
@@ -612,7 +611,7 @@ protected:
// select input device corresponding to requested audio source
virtual audio_devices_t getDeviceForInputSource(audio_source_t inputSource,
- String8 *address = NULL);
+ AudioMix **policyMix = NULL);
// return io handle of active input or 0 if no input is active
// Only considers inputs from physical devices (e.g. main mic, headset mic) when