Audio manager routing priority

The audio manager allows clients to manually control the routing of their streams.

The main audio audio device supports only a main mix, therefore the routing of the highest priority audio stream is the one that is chosen. If a client does not specify a manual routing path, the routing path is automatically selected for it based on the priority of the connected audio devices in that mode.

The following table lists the audio types, in descending order of priority (that is, the higher the audio type is in the table, the higher its priority). For example, if AUDIO_TYPE_DEFAULT is the type of the active stream, and a second stream of type AUDIO_TYPE_VIDEO_CHAT begins, the routing, tuning, and attenuation policy of the AUDIO_TYPE_VIDEO_CHAT stream take effect, since it has the higher priority.

For each audio type, the effect on lower priority audio streams is listed:
  • muted — lower priority streams are muted for a non-transient event, like a phone call. It this case it might be appropriate for the applications generating the lower priority audio streams to pause for the duration of the event.
  • fully attenuated — lower priority streams are muted for a transient event, such as a camera click. The applications might not need to react in this case.
Name Description Concurrency Rule
AUDIO_TYPE_SOUND_EFFECT Sound effects that can never be attenuated, such as the camera click. Fully attenuates all lower priority audio streams.
AUDIO_TYPE_RINGTONE Used for playback of ringtones when an incoming phone call occurs. Fully attenuates all lower priority audio streams.
AUIDO_TYPE_VOICE_TONES DTMF and call progress tones. Can also be used to playback non-tone based audio during phone call however. Fully attenuates all lower priority audio streams.
AUDIO_TYPE_VOICE Voice band related streams, and specific things related to telephony (cellular or VOIP). Mutes all lower priority audio streams.
AUDIO_TYPE_VIDEO_CHAT Used by the video chat client. This type is not covered by AUDIO_TYPE_VOICE because of a difference in automatic routing policy. Mutes all lower priority audio streams.
AUDIO_TYPE_PUSH_TO_TALK Used to denote streams related to push-to-talk use cases. Fully attenuates all lower priority audio streams.
AUDIO_TYPE_VOICE_RECOGNITION Voice recognition services, like VAD. Mutes all lower priority audio streams.
AUDIO_TYPE_TEXT_TO_SPEECH Text to speech services. Attenuates lower priority audio streams by 40%.
AUDIO_TYPE_ALERT Notifiers, such as for calendar events, email, SMS, instant messaging, and so on. Attenuates lower priority audio streams by 40%.
AUDIO_TYPE_VOICE_RECORDING Voice recording services, like Focal points. No change to other streams.
AUDIO_TYPE_MULTIMEDIA Used by media player applications. No change to other streams.
AUDIO_TYPE_DEFAULT Any unclassified audio stream is of type default. No change to other streams.

Last modified: 2013-12-21

comments powered by Disqus