• Home
  • History
  • Annotate
  • only in /frameworks/av/media/libaudioclient/
History log of /frameworks/av/media/libaudioclient/
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
1d32e9f8e5ba52d69c6319270c8a63a995d2c4f2 02-Jun-2017 Eric Laurent <elaurent@google.com> aaudio: implement native IPLayer for legacy playback streams

Make AudioStreamTrack derive from PlayerTrackBase to
provide playback and volume control via IPLayer interface.

Bug: 62027849
Test: verify aaudio playback regressions and registration of aaudio
players in AudioService

Change-Id: I5c04110f1554233eae3f1bc357a64a584d7303d1
layerBase.cpp
nclude/media/PlayerBase.h
b5323222bd524876dda1ebf89694f186278e2229 01-Jun-2017 Eric Laurent <elaurent@google.com> add native IPlayer interface implementation

Generalized the IPlayer implementation done for OpenSL ES
so that it can be used by other native audio players
Created two classes:
- PlayerBase implementing the interfacin native AudioManager and
IPlayer methods
- TrackPlayerBase, a derived class specialized for AudioTrack.

Bug: 62027849
Test: verify regressions with OpenSL ES buffer queue player

Change-Id: If5ad21a3c1a243fba0b312001c5034102e6d6672
ndroid.bp
layerBase.cpp
rackPlayerBase.cpp
nclude/media/PlayerBase.h
nclude/media/TrackPlayerBase.h
fb00fc77f59ed5ebec4d38bac666e6521b6c1de0 26-May-2017 Eric Laurent <elaurent@google.com> aaudio: fix device switch detection in legacy path

Implement device switch detection on legacy path (AudioTrack and
AudioRecord) based on audio routing callbacks forcing the stream state
to disconnected.

Bug: 33355262
Bug: 62090113
Test: tested with write_sine and input_monitor command line tools.
Change-Id: I9e0421fee233964b1bf318acb640569196a00f13
udioRecord.cpp
udioSystem.cpp
udioTrack.cpp
382d11ac489a917d3d009c3d05bc960f4af58176 23-May-2017 Phil Burk <philburk@google.com> aaudio: allow AudioRecord to use FAST mode for TRANSFER_SYNC

Bug: 34093052
Test: loopback.cpp
Change-Id: I3bf4ee6f58fad017a038edfd50475d5dd5a4fca5
Signed-off-by: Phil Burk <philburk@google.com>
udioRecord.cpp
f370264dfa5237524a3535f5242a0c68cbbb13eb 06-May-2017 Andy Hung <hunga@google.com> VolumeShaper: Fixes for updated Cts test

1) Limit number of VolumeShapers that can be created.
a) 16 system VolumeShapers
b) 16 application/client VolumeShapers
2) Return proper volume before VolumeShaper is started.
3) Consistent xOffset definition used internally:
a) this is now always the position on the volumeshaper curve
which can go backwards if in REVERSE.
b) normalized time is always forward going and is scaled
to 0.f and 1.f depending on progress relative to
the curve's duration.
4) Fix replace method.
5) Add comments.

Test: Use updated CTS VolumeShaperTest
Bug: 37536598
Change-Id: I837ab2a481adc0abbd3f1338bfe2cb79831b11fa
udioTrack.cpp
nclude/media/AudioTrack.h
39399b6b08b4e9fd7eae50e58e93b07216ad697f 22-Apr-2017 Andy Hung <hunga@google.com> VolumeShaper: Improve restore

Consider whether VolumeShaper has been started or not when
restoring (position). If the VolumeShaper hasn't been started
we restore in that state. If it has been started already,
we advance to the end assuming the duration has been played out.

Test: CTS and headset / kill audioserver
Bug: 37536598
Change-Id: I4b55dca6f6a859563fd20bad4c8f67d2c92321c0
udioTrack.cpp
25a9e5561a7f14e79b04f713a515a9464b9ea077 17-Apr-2017 Steven Moreland <smoreland@google.com> Add libaudioclient_headers

Test: works with BOARD_VNDK_VERSION := current
Bug: 33241851
Change-Id: I31cf7e7cd89fe6e71d4e52f7682990146a12b2fb
ndroid.bp
AudioFlinger.cpp
nclude/AudioBufferProvider.h
nclude/AudioEffect.h
nclude/AudioIoDescriptor.h
nclude/AudioMixer.h
nclude/AudioParameter.h
nclude/AudioPolicy.h
nclude/AudioPolicyHelper.h
nclude/AudioRecord.h
nclude/AudioSystem.h
nclude/AudioTimestamp.h
nclude/AudioTrack.h
nclude/IAudioFlinger.h
nclude/IAudioFlingerClient.h
nclude/IAudioPolicyService.h
nclude/IAudioPolicyServiceClient.h
nclude/IAudioRecord.h
nclude/IAudioTrack.h
nclude/IEffect.h
nclude/IEffectClient.h
nclude/ToneGenerator.h
nclude/media/AudioBufferProvider.h
nclude/media/AudioEffect.h
nclude/media/AudioIoDescriptor.h
nclude/media/AudioMixer.h
nclude/media/AudioParameter.h
nclude/media/AudioPolicy.h
nclude/media/AudioPolicyHelper.h
nclude/media/AudioRecord.h
nclude/media/AudioSystem.h
nclude/media/AudioTimestamp.h
nclude/media/AudioTrack.h
nclude/media/IAudioFlinger.h
nclude/media/IAudioFlingerClient.h
nclude/media/IAudioPolicyService.h
nclude/media/IAudioPolicyServiceClient.h
nclude/media/IAudioRecord.h
nclude/media/IAudioTrack.h
nclude/media/IEffect.h
nclude/media/IEffectClient.h
nclude/media/ToneGenerator.h
bc942724f95c6e30e640e33c2b35157367714c1c 13-Apr-2017 Phil Burk <philburk@google.com> Merge "AudioTrack and AudioRecord: getNotificationPeriodInFrames()" into oc-dev
b588402d48c9634fa72e7e13ca6d6f2a0766cb98 28-Mar-2017 Phil Burk <philburk@google.com> AudioTrack and AudioRecord: getNotificationPeriodInFrames()

This is needed for AAudioStream_getFramesPerBurst(),
which is needed for callbacks to work correctly.

Bug: 34716038
Bug: 36489240
Test: CTS test_aaudio.cpp
Change-Id: I0e3f3f18a22bf6da8c288f0d2caec0bff0153f2f
Signed-off-by: Phil Burk <philburk@google.com>
nclude/AudioRecord.h
nclude/AudioTrack.h
6d8018f0b7be9deec6b0acab10a0dca6e91d0fb8 21-Feb-2017 Glenn Kasten <gkasten@google.com> Improve audio logs and dumpsys media.audio_flinger

Include mFrameCount in shared memory corrupt error log.

Fix typo in log for primary audio interface.

Include the new server frame count in logs for fast tracks.

Always log when fast is successful for output tracks, as it helpful
(was already there for input).

Cleanup dumpsys for threads.

Bug: 37153050
Test: builds OK, and logs contain more information
Change-Id: I2b5b4d700e8eb7c261a3125fb03ddc00bf08537e
(cherry picked from commit 1bfe09a0b1755a79abd32b41c0dd433b88fc260c)
udioRecord.cpp
udioTrack.cpp
udioTrackShared.cpp
4a71e75dc56415cda4cf33ea92d4efd914a44541 15-Mar-2017 Glenn Kasten <gkasten@google.com> Merge "ToneGenerator: support output sample rates beyond 65535 Hz"
886deb506ea2938cfec40fc0dd2bff072850386b 13-Mar-2017 Glenn Kasten <gkasten@google.com> Merge "Re-format to decrease the maximum line length of files to 100 characters"
d3bb645f0b7f567b033b8664499d685f8ec10628 06-Dec-2016 Glenn Kasten <gkasten@google.com> Re-format to decrease the maximum line length of files to 100 characters

Test: compiles OK
Change-Id: Ibe663032cd390ed2bcca6dc921d47732e6e15e21
udioRecord.cpp
udioSystem.cpp
udioTrack.cpp
b53dae6ea693561cd5e3dae1ec112949cb079b2c 17-Jan-2017 Glenn Kasten <gkasten@google.com> ToneGenerator: support output sample rates beyond 65535 Hz

Changed type of ToneGenerator::WaveGenerator constructor parameter
samplingRate from unsigned short to uint32_t to permit output
sample rates such as 96000 Hz.

Bug: 33969539
Test: dialer tones work when output sink operates at 96000 Hz
Change-Id: I5551409c467a4fd98ea4d5c9703b120a526a443e
oneGenerator.cpp
nclude/ToneGenerator.h
dcdfaecc1fa630a799e1fdb508a9b92da55abc36 14-Feb-2017 Nicolas Roulet <nicoroulet@google.com> NBLog periodic merging thread

Bug: 35468674
Test: no change in functionality, everything works as before
Change-Id: Id2cea243bc15767ca6803c9505bf23a18411500e
AudioFlinger.cpp
4ef88d7106c01f81109ee163cb6789073d80c6ae 22-Feb-2017 Andy Hung <hunga@google.com> VolumeShaper: Add AudioTrack restore

MediaPlayer VolumeShaper can now be set before start().

Test: CTS and Ducking
Bug: 31015569
Change-Id: Idf63c167e164161b200e2467fbeb9409b3097dbe
udioTrack.cpp
nclude/AudioTrack.h
e2b43843fd12783188edd2c54188ea8d26864788 02-Feb-2017 Vijay Venkatraman <vijaykv@google.com> Moved headers from include/ to appropriate libs

include/camera -> camera/include/camera
include/media/audiohal -> media/libaudiohal/include
include/media/AudioResampler*.h -> media/libaudioprocessing/include
include/media/Audio*.h,IAudio*.h,IEffect*.h,ToneGenerator.h -> media/libaudioclient/include
include/media/EffectsFactoryApi.h -> media/libeffects/include
include/media/stagefright -> media/libstagefright/include
include/media/nbaio -> media/libnbaio/include
include/media/<rest of files> -> media/libmedia/include
include/cpustats -> media/libcpustats/include/cpustats

Added symlinks from old location to new ones

Bug: 33241851

Test: VNDK linked modules will need to add explicit lib dep.
All other modules should compile the same

Change-Id: I0ecf754a2132640ae781a3cc31428fb8c0bd1669
ndroid.bp
nclude/AudioBufferProvider.h
nclude/AudioEffect.h
nclude/AudioIoDescriptor.h
nclude/AudioMixer.h
nclude/AudioParameter.h
nclude/AudioPolicy.h
nclude/AudioPolicyHelper.h
nclude/AudioRecord.h
nclude/AudioSystem.h
nclude/AudioTimestamp.h
nclude/AudioTrack.h
nclude/IAudioFlinger.h
nclude/IAudioFlingerClient.h
nclude/IAudioPolicyService.h
nclude/IAudioPolicyServiceClient.h
nclude/IAudioRecord.h
nclude/IAudioTrack.h
nclude/IEffect.h
nclude/IEffectClient.h
nclude/ToneGenerator.h
9fc8b5cd4a64ef07e84c69112461324d5c13a0b0 24-Jan-2017 Andy Hung <hunga@google.com> VolumeShaper: Initial implementation

The VolumeShaper is used to apply a volume
envelope to an AudioTrack or a MediaPlayer.

Test: CTS
Bug: 30920125
Bug: 31015569
Change-Id: I42e2f13bd6879299dc780e60d143c2d465483a44
udioTrack.cpp
AudioTrack.cpp
fff204c192f7e16c635a79f6a85786afb8522a3d 13-Jan-2017 Andy Hung <hunga@google.com> AudioTrack: Control deep buffer from AudioAttributes

Test: AudioTrack CTS test, Play Movies
Bug: 30687201
Change-Id: I6a46a05dbf3fd61c8d47dade5b4baee69b923195
udioTrack.cpp
d7c5ec857930496bb8a1045dc8b87b2fdd99899c 11-Jan-2017 Pavlin Radoslavov <pavlin@google.com> Merge "Add missing nullptr checks for data.readCString() strings" am: ce961d374f am: 238c48e42e am: 877f779979
am: 4b058e7e5d

Change-Id: Idc3298b161380e9ace8b7fcceb4339b0805a3123
4b058e7e5d58fb1bc6ba82eba94f7664e5b85706 11-Jan-2017 Pavlin Radoslavov <pavlin@google.com> Merge "Add missing nullptr checks for data.readCString() strings" am: ce961d374f am: 238c48e42e
am: 877f779979

Change-Id: Ic6e96b9ff3ecc609c40f8c5d5367a789b3732b7e
877f77997987212ae0fbfecb24b35c03a0573006 11-Jan-2017 Pavlin Radoslavov <pavlin@google.com> Merge "Add missing nullptr checks for data.readCString() strings" am: ce961d374f
am: 238c48e42e

Change-Id: I2e9cb8ec6752506cc5445aee3d38ae92e4f5e514
c694ff449bef4ca1e45a6506f34e66c613757311 10-Jan-2017 Pavlin Radoslavov <pavlin@google.com> Add missing nullptr checks for data.readCString() strings

Protect the Audio Policy Manager by adding extra checks
for data.readCString() strings when parsing / decoding
a Binder transaction.

Also:
* Moved audio_is_output_device() / audio_is_input_device() checks
inside handleDeviceConfigChange()
from the AudioPolicyInterface to the AudioPolicyManager
* Removed similar redundant checks inside
AudioPolicyService::setDeviceConnectionState()

Test: code compilation
Change-Id: Ib32a28ba2669b73aaf32b31bb18f41c8dd7d2605
AudioPolicyService.cpp
c02c861e7377ab63d3d59b6220afafd625f53aaf 10-Jan-2017 Jack He <siyuanh@google.com> Merge "Convert Android.mk in libaudioclient to Android.bp" am: 0da9804f12 am: 05dfbecf27 am: 19031e678e
am: cb680c9cc4

Change-Id: If508ad957671ed199bd25fba58cd9af2a261fc3a
cb680c9cc4009261dd2fbe40a1a585737746589d 10-Jan-2017 Jack He <siyuanh@google.com> Merge "Convert Android.mk in libaudioclient to Android.bp" am: 0da9804f12 am: 05dfbecf27
am: 19031e678e

Change-Id: I528e03e58d8a34316cf8270d3bb2b5b5d828eee1
19031e678e977a25490be092dc4f7005e396a9de 10-Jan-2017 Jack He <siyuanh@google.com> Merge "Convert Android.mk in libaudioclient to Android.bp" am: 0da9804f12
am: 05dfbecf27

Change-Id: I855fe9d7f9d6302eda5e5f3d747a10b2d3b3b193
d92d34e86cca348097cea2afa3ddb009572b9303 09-Dec-2016 Jack He <siyuanh@google.com> Convert Android.mk in libaudioclient to Android.bp

* Since system/bt depends on this library, it needs to be converted to
Android.bp before the conversion in system/bt can be continued.
* Majority of work is done by androidmk Android.mk > Android.bp
* Fixed sanitize arguements
* Removed LOCAL_EXPORT_C_INCLUDE_DIRS as Android.bp only supports
exporting sub-directories of current Android.bp file
* Removed frameworks/av/media/libmedia/aidl include path as it no longer
exists and Android.mk failed to check that
* Removed include path for audio-utils as it is being automatically
included when we link against libaudioutils
* Android.mk file must be deleted as a library of the same name can only
be defined once in either Android.bp or Android.mk
* A library defined in Android.bp can be used by either Android.bp or
Android.mk files. However, a library defined in Android.mk cannot be
used by Android.bp file. Therefore, for system/bt to link against this
library in the Android.bp, this library must be converted first

Bug: 32958753
Test: Code compilation, no user visible effect

Change-Id: I2ae87a1151ed4235122c7774096c2dbff8b1fc62
ndroid.bp
ndroid.mk
5fd7ccaeba88da7e170f067bfd754b3f64ff5566 29-Dec-2016 Pavlin Radoslavov <pavlin@google.com> Merge "Add a mechanism for handling audio device configuration change" am: 549e431947 am: a1b496ac35 am: fcc1132010
am: c6fe843463

Change-Id: I7812e3e4426e526b886c1a414ac8ddec7649291e
c6fe843463abc965f3082738c8812506cf5ba232 29-Dec-2016 Pavlin Radoslavov <pavlin@google.com> Merge "Add a mechanism for handling audio device configuration change" am: 549e431947 am: a1b496ac35
am: fcc1132010

Change-Id: I4c25c229b0bb8a385a231c7a9f444b923bb46456
fcc113201018703727a0d6b17dd165efce00db1a 29-Dec-2016 Pavlin Radoslavov <pavlin@google.com> Merge "Add a mechanism for handling audio device configuration change" am: 549e431947
am: a1b496ac35

Change-Id: Ie8871fad611dc16d7cd08a85e4cd748cf3c4650d
f862bc6a7a35054e38cb50fa16ae7a07f683ee01 27-Dec-2016 Pavlin Radoslavov <pavlin@google.com> Add a mechanism for handling audio device configuration change

* Added new call handleDeviceConfigChange() to the Media Framework.
That call can be used when there are device configuration changes
(e.g., Bluetooth A2DP codec configuration has changed).
* Added new method AudioPolicyManager::handleDeviceConfigChange().
That method toggles the UNAVAILABLE/AVAILABLE connection state of the
device, so it can be reconfigured as appropriate - e.g., the audio
feeding parameters can be updated.
* Fix ALOGVV compilation errors when extra logging is enabled.

Test: A2DP streaming to headsets
Bug: 30958229
Change-Id: I388abbbb3ec4d1a003b441cb0c77e00d80cad668
udioSystem.cpp
AudioPolicyService.cpp
0ca38308c75568d571016c0e24fb8246bbf239b6 01-Nov-2016 Kiran Kumar Krishna <kiran@motorola.com> AudioRecord: fix AudioRecordThread crash upon exit

In case of error during openRecord_l(), there is a possibility
that a newly created AudioRecordThread is resumed by requestExit()
just after entering the Thread class _threadLoop() but before
entering the class threadLoop(). In this case, processAudioBuffer()
is executed once with mCblk == 0 and we assert.

Test: test case at bug
Bug: 29993798
Change-Id: I15d4f138218f6f01a020c4fc568a5b4831cb92a7
udioRecord.cpp
6a308b02f138e358fb239ee2df5d54dd988f34fd 16-Dec-2016 Eric Laurent <elaurent@google.com> Merge "Add unique audio port IDs to AudioTrack and AudioRecord"
20b9ef0b55c9150ae11057ab997ae61be2d496ef 05-Dec-2016 Eric Laurent <elaurent@google.com> Add unique audio port IDs to AudioTrack and AudioRecord

This will allow to track activity at the track level instead of
at audio session level as only possible with current implementation.

AudioTracks and AudioRecords will receive a unique audio port ID the
first time they register to audio policy with
getOutputForAttr()/getInputForAttr() and keep this ID for their
lifetime.

This CL is the first partial change and just updates the
audio policy and audio flinger APIs used at track creation time.

Test: basic regression test of audio playback and capture use cases

Change-Id: I8d612e67738e120494f61e3f7c60bfd0b2c6a329
udioRecord.cpp
udioSystem.cpp
udioTrack.cpp
AudioFlinger.cpp
AudioPolicyService.cpp
b643627a557e44b9ab5879cf71e162af2d514ce3 08-Dec-2016 Eric Laurent <elaurent@google.com> fix client pid for effects applied by audio policy

Test: Hangouts call, Play Music with and w/o effects

Change-Id: Ia9b20f94be667dd92e0497f8ef9c0dc0e95afe28
udioEffect.cpp
AudioFlinger.cpp
78cbdfa7b68615cc61573f39a87563d891aed652 07-Dec-2016 Andy Hung <hunga@google.com> Log audio information to ensure complete delivery
am: 1f82f9569d

Change-Id: I8c3045b0331a97b98168897d03ec1dc55235a59e
abf6ff26df459d991cdbc2dca3b78046c97469db 03-Dec-2016 Andy Hung <hunga@google.com> Merge "Log audio information to ensure complete delivery"
2148bf0e79c436b8764b9edc4c8f2730cce98a32 29-Nov-2016 Andy Hung <hunga@google.com> Log audio information to ensure complete delivery

Test: Audio playback
Bug: 30572472
Change-Id: Ibad6fc202692cd3480ae726627252afdead083f3
udioTrack.cpp
c64e124bca8b7813ecea19d38452dd55fee4082f 30-Nov-2016 rago <rago@google.com> Fix security vulnerability: potential OOB write in audioserver am: e275907e57 am: 01e854056a am: 3e8ab60b7f am: 9161586309 am: ad29b47d91 am: 8b9b199891 am: 72729c449d am: 97bb7fe084 am: 3d6aada999 am: ffe82a3b4a am: ec601622f8 am: f50635bdc4 am: f1e829a54e am: a2e95f5c9b am: c6239b0d4d
am: cbc7183fbb

Change-Id: I7a13718ab24d1c4c9c64d83e148031af046921e1
c6239b0d4dfa730c122f2de214dfd2e62f7f8eea 30-Nov-2016 rago <rago@google.com> Fix security vulnerability: potential OOB write in audioserver am: e275907e57 am: 01e854056a am: 3e8ab60b7f am: 9161586309 am: ad29b47d91 am: 8b9b199891 am: 72729c449d am: 97bb7fe084 am: 3d6aada999 am: ffe82a3b4a am: ec601622f8 am: f50635bdc4 am: f1e829a54e
am: a2e95f5c9b

Change-Id: Ic25053a111913dfd4490633b9f0eff1e7fe1d359
41cbae72e4e223c15ba2d85b3c27ed31d1bf5f86 12-Nov-2016 Glenn Kasten <gkasten@google.com> Merge "AudioRecord: fix AudioRecordThread crash upon exit"
e813ef9388e9f0b821c0a434521f0e194288c8ad 01-Nov-2016 Kiran Kumar Krishna <kiran@motorola.com> AudioRecord: fix AudioRecordThread crash upon exit

In case of error during openRecord_l(), there is a possibility
that a newly created AudioRecordThread is resumed by requestExit()
just after entering the Thread class _threadLoop() but before
entering the class threadLoop(). In this case, processAudioBuffer()
is executed once with mCblk == 0 and we assert.

Test: test case at bug
Bug: 29993798
Change-Id: I15d4f138218f6f01a020c4fc568a5b4831cb92a7
udioRecord.cpp
1f12a8ad958344c50733b948628ffa06db9c5bc6 08-Nov-2016 Andy Hung <hunga@google.com> Audio: Use uid_t for uids

Test: Power manager shows correct uids for audio
Bug: 32713790
Change-Id: If5337e17283268f74dc0f00cc66ece9153d680ef
udioRecord.cpp
udioTrack.cpp
4ea929819e23ecd388e1edce25a10631ee53e9e3 07-Nov-2016 Marco Nelissen <marcone@google.com> Split libmedia into libmedia and libaudioclient
am: 795a2a7554

Change-Id: Ic08eddc5650d3f5d344ebcf93ad98ae5bb236c8c
795a2a75542d25eefa56bebc388340ee15fdff5c 02-Nov-2016 Marco Nelissen <marcone@google.com> Split libmedia into libmedia and libaudioclient

This makes it so audioserver doesn't need to link against the entire libmedia,
which has dependencies on camera, ICU, OpenGL and other things that aren't
needed for audio.

Test: build/boot

Change-Id: I99ba1a3dc3b33ca9b3abd98e7519dbf228ee62af
ndroid.mk
udioEffect.cpp
udioPolicy.cpp
udioRecord.cpp
udioSystem.cpp
udioTrack.cpp
udioTrackShared.cpp
AudioFlinger.cpp
AudioFlingerClient.cpp
AudioPolicyService.cpp
AudioPolicyServiceClient.cpp
AudioRecord.cpp
AudioTrack.cpp
Effect.cpp
EffectClient.cpp
oneGenerator.cpp
538ec5e04f389cba637b030757be317fcb8677a8 02-Nov-2016 Marco Nelissen <marcone@google.com> Split libmedia into libmedia and libaudioclient

This makes it so audioserver doesn't need to link against the entire libmedia,
which has dependencies on camera, ICU, OpenGL and other things that aren't
needed for audio.

Test: build/boot

Change-Id: I99ba1a3dc3b33ca9b3abd98e7519dbf228ee62af
ndroid.mk
udioEffect.cpp
udioPolicy.cpp
udioRecord.cpp
udioSystem.cpp
udioTrack.cpp
udioTrackShared.cpp
AudioFlinger.cpp
AudioFlingerClient.cpp
AudioPolicyService.cpp
AudioPolicyServiceClient.cpp
AudioRecord.cpp
AudioTrack.cpp
Effect.cpp
EffectClient.cpp
oneGenerator.cpp