Also:
- use %x format for logging channel masks
- use AUDIO_CHANNEL_IN_* constants from system/audio.h instead of AudioSystemLegacy.h symbols
- remove redundant casts
- use "channelMask" instead of "channels" to avoid possible confusion with channel counts
Change-Id: If05d6b1cae5cf1b560cd53a93ae9e592b719ec9e
Changes to the API of audio policy for audio offload support:
- Add isOffloadSupported() function
- Add OUTPUT_FLAG_OFFLOAD
- Extend AudioOutputDescriptor to include a sharing count for direct outputs
- Pass audio_offload_info_t when opening output streams
Change-Id: I5ad26418fdb286eb7ae299d586dd1fd525d48ab9
Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com>
Signed-off-by: Eric Laurent <elaurent@google.com>
Add support for checking remote stream activity.
Don't route notifications like media when media active remotely.
Add remote stream activity query in audio policy HAL.
Bug 7485803
Change-Id: Ifb722c7f9ffbfbdc877fec5156bcfc09bec40651
Add support for querying whether there is currently a recording
underway from the specified audio source.
Bug 7314859
Change-Id: I8894845b176241134870af5df2bebc5ef27e4de4
The AudioPolicyManagerBase implementation was using some device
enum values from AudioSystemLegacy.h, of type audio_devices,
and some from /system/audio.h, of type audio_devices_t.
Now only uses audio_devices_t, and associated functions to
inspect what audio device type they correspond to.
Added #define to represent "no audio device" to clarify code.
Removed unused variable in AudioPolicyManagerBase::startOutput()
Change-Id: Ibec311dac550d6a806397377206a43bc708914c0
Audio hw modules are now loaded according to configuration
data read from audio_policy.conf. They are not loaded anymore
from a hardcoded list in AudiFlinger.
Output and input streams are opened on the hw module by which
they are exposed.
Also removed obsolete "acoustics" flags for input streams.
Change-Id: I8dc658cc83890d3ac7d5e36c372a03732aa5b0c4
Map the NOTIFICATION stream type to a new strategy,
named STRATEGY_NOTIFICATION_RESPECTFUL, which differs
from STRATEGY_NOTIFICATION in that, when media is
playing, the notifications will use the same output
as the MEDIA strategy. This will results in the
notifications not being duplicated on the speaker
when a headset is in use for media playback.
Change-Id: I032be0e2d383c69b5b6c912d7174753f5572c4b4
Improve volume management by keeping track of volume for each type
of device independently.
AudioPolicyManagerBase now keeps track of stream volumes for each device
and apply volume according to current device selection.
Methods to set and get stream volume now specify the device class.
A value for "default" device is always present for each stream and is used
if a device is selected and no specific volume was ever set for this device.
Change-Id: I06d8f43aa151a09014f7e47e81304c73ff82e9f8
Audio effect CPU usage is now registered on enable and
unregistered on disable instead of when the effect is
created or destroyed.
Change-Id: Icffcede9558d8d41887278f0efef2df430927381
This doesn't actually create a HAL, but rather a set of helper static
libraries that device specific libraries (i.e. the old libaudio pieces)
can link against to create a proper audio HAL module.
We provide an audio_policy static wrapper and audio hardware interface
static wrapper.
Change-Id: Ie56195447ad24b83888f752dca24674b0afd8a76
Signed-off-by: Dima Zavin <dima@android.com>
Move isStreamActive() method from AudioFlinger to AudioPolicyManager.
iStreamActive() now specifies a time window during which the stream is considered
active after it actually stopped.
Change-Id: Ib0d7d8f061b9f809d307ecfac40960ef582e5f0f
Added an initCheck() method to AudioPolicyInterface to verify
successful initialization of AudioPolicyManager.
Change-Id: I4c892282dbeb3246ee6c006bd206a3e723bcb71f
Added methods for audio effects management by audio policy manager.
- control of total CPU load and memory used by effect engines
- selection of output stream for global effects
- added audio session id in parameter list for startOutput() and stopOutput().
this is not used in default audio policy manager implementation.
Change-Id: I3467e64035387cc5272266b1318a5ed788958374