History log of /frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
7f68013dd65638b6688d17f53641d2f8f7fc2e09 12-Mar-2018 Phil Burk <philburk@google.com> audio: check for negative sizes in conversion

Check for negative parameters in AAudioConvert_framesToBytes().

Bug: 74548911
Test: run CTS
Change-Id: I42903b9c7f710a34a8689431e57c084a9959d0e0
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
41f19d8e9471945b358c9ae1dffda60f195d9f5b 13-Feb-2018 Phil Burk <philburk@google.com> aaudio: convert mono output to stereo

MMAP hardware streams are often stereo.
But apps often want to output a mono stream.
Since converting from mono to stereo is easy,
we can go ahead and open a stereo hardware stream
and then just convert the apps mono data to stereo for the HW.

Add getDeviceChannelCount().

Test: adb shell write_sine_callback -pl -s10 -c1 -m3
Test: adb shell write_sine_callback -pl -s10 -c1 -m3 -x
Change-Id: I444a38c6f5cd32d1d6113f16aacec68285a1bc82
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
67fdd894bf7e09a544348a9f8298427bc9b3fe85 24-Jan-2018 Phil Burk <philburk@google.com> aaudio: fix sessionId conversion

Was not handling negative IDs correctly.
Update test to allow negative IDs.

Bug: 72333892
Test: CTS has test_session_id
Change-Id: I1ca57026d6202f7d54c8efd51b14854be6cc69e4
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
5cc83c3b8acc43b760be23a4e3b96fbbb06d8e93 29-Nov-2017 Phil Burk <philburk@google.com> aaudio: fix some state transitions

Now requestStop() and requestPause() do the appropriate thing
based on state.
Flush is allowed when OPEN, PAUSED or STOPPED because there might
be pre-roll data.

Bug: 69810494
Test: test_various.cpp
Change-Id: Ie1b306b17734a58fa71b1742bb186482893656b7
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
6d7582e9ad858301b3eeff7b187af6c34808cb7e 12-Jan-2018 Kevin Rocard <krocard@google.com> Audio V4: Use the framework audio.h instead of the HAL's

Using the legacy HAL interface was not needed. Only the system audio
header types are used by aaudio.

Test: compile
Bug: 38184704
Change-Id: I321635ef79732eb20864d1349e6a13911ece8da5
Signed-off-by: Kevin Rocard <krocard@google.com>
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
4e1af9fc9c1108d4514e92774f750bcd434dbbcc 04-Jan-2018 Phil Burk <philburk@google.com> aaudio: implement sessionId for effects

If a sessionID other than AAUDIO_SESSION_ID_NONE is requested
then legacy data path will be forced.

SessionID is implemented for MMAP data path but not used.
It is easier to implement it now then try to figure
it out later.

Bug: 33268927
Test: test_session_id.cpp will be moved to CTS when stable
Change-Id: I3ea67f57c1cbe24a512980f1352b917ab3cb6387
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
d4ccc624201d5c74ff6e14db1b68743b41fe795c 21-Dec-2017 Phil Burk <philburk@google.com> aaudio: implement new USAGE, CONTENT_TYPE and INPUT_PRESET

Pass these audio attributes to AudioFlinger.

Bug: 68052449
Bug: 62104146
Test: test_attributes.cpp will be moved to CTS when ready
Change-Id: Ib8804614d95dcf1b85e51ec1f5569892e017a991
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
2d5ba532cc80b3408b9eb5d47d3144bf93ece8cd 06-Sep-2017 Phil Burk <philburk@google.com> aaudio: prevent noise upon disconnect

Also clean up the state machine handling in the data callback.
Prevent error callback sometimes being called twice for the same error.

Bug: 63342351
Bug: 63087953
Test: add sleep(2) to write_sine_callback.cpp before the requestStop()
Change-Id: I27737bcb0371052741f50bda9f65c5994ccf6fd9
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
bcc3674648bc6f554d89a2a5d7721ed41c53f83b 01-Sep-2017 Phil Burk <philburk@google.com> aaudio: fix timestamps and underruns

Start the client after we get valid timing data from the server.
That can take a while because of the long cold start times.
The client is synced with the current position of the service.
Now the client can start clean with no underruns.

Bug: 63918065
Test: test_timestamps.cpp
Change-Id: I5d01eb844e4b14cd5477d56ea1dd9e309abc1c52
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
97350f9df7252c881f011a410fcd9e6d766d2bee 22-Jul-2017 Phil Burk <philburk@google.com> aaudio: improve accuracy of timestamps

Account for latency added by the AAudio service.
Fix input timestamps.

Bug: 37080396
Test: test_timestamps.cpp input_monitor.cpp
Change-Id: I1053cd21af722bb9b9371df4e5731bf4a0a57b0b
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
fd34a9310659aa53e9e10d6826651577a75f6447 19-Jul-2017 Phil Burk <philburk@google.com> aaudio: reduce glitching by improving sleep timing

ALways sleep a minimum time to avoid busy wait in real-time thread.
Account for wakeup jitter in threads on the other side of a FIFO.
Avoid race condition that caused a longer sleep than necessary.
Fix calculation of mFreeRunning for capture mode.

Also added systrace logging, which was used to debug this.

Bug: 63814792
Test: Run GStomper on Walleye with MMAP on, see bug
Change-Id: I7b20098580ff454365425bd21e43c17ade532a0a
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
47c5e530b01b620a4f65efa121a938789a6823b4 27-Jun-2017 Andy Hung <hunga@google.com> AAudioService: add dumpsys capability

Test: adb shell dumpsys media.aaudio
Bug: 38396780
Change-Id: I8b5c421bdd1b3228d8140816a68740709aa9757b
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
897011a94008cb9ab73f8db397bbd87c57f5cf27 31-May-2017 Glenn Kasten <gkasten@google.com> Merge "aaudio: remove deprecated aaudio_audio_format_t" into oc-dev
d04aeea00bdaa999821e1a15c437ea648bd07195 23-May-2017 Phil Burk <philburk@google.com> aaudio: AAudio_setMMapPolicy()

Controls whether MMAP data path is used NEVER, AUTO or ALWAYS
For testing only. To improve code coverage in CTS.

Bug: 38268547
Test: write_sine.cpp
Change-Id: Iad97876fb6f1d0c653262161b7b5519d83d16ac5
Signed-off-by: Phil Burk <philburk@google.com>
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
9dca9824da74d50be02bc81f539cc77b7bde678a 26-May-2017 Phil Burk <philburk@google.com> aaudio: remove deprecated aaudio_audio_format_t

Should be using aaudio_format_t

Bug: 62141619
Test: compile and run CTS test_aaudio.cpp
Change-Id: Ibbba2769dfd8bcd9c108d87c19fe1fad2ba43df1
Signed-off-by: Phil Burk <philburk@google.com>
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
c8f69a08a409fd163873d725c63f8d60259ae21d 12-May-2017 Phil Burk <philburk@google.com> aaudio: control MMAP mode using system properties

To facilitate testing of MMAP mode.

Bug: 38268547
Test: set properties, see framesPerBurst in write_sine_callback.cpp
Change-Id: I6e15c563215017f6a5020d89ac312ff8331afc4f
Signed-off-by: Phil Burk <philburk@google.com>
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
e572f469de5dca1078a79d3d80e5b04f96ae7505 20-Apr-2017 Phil Burk <philburk@google.com> aaudio: apply volume in the MMAP data path

The volume scaling is in AudioStreamInternal and not the mixer
because we will need volume scaling in EXCLUSIVE mode too.

Bug: 37518243
Test: play a tone using NativeOboe app then press volume keys
Change-Id: Ibbac9770ea4493f8ade64681be86f109a92803cd
Signed-off-by: Phil Burk <philburk@google.com>
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
a4eb0d86a29be2763be5fac51727858d5095794b 13-Apr-2017 Phil Burk <philburk@google.com> aaudio: merge contents of AAudioDefinitions.h into AAudio.h

As requested by native API council.

Bug: 30210002
Bug: 33398120
Test: CTS test_aaudio
Change-Id: I5ea7c53d09469221263d84cf6f82082e67c2523b
Signed-off-by: Phil Burk <philburk@google.com>
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
3316d5e6d375a4f09c681205e9094d30a0bfc4a2 15-Feb-2017 Phil Burk <philburk@google.com> libaaudio: changes for API council

Removed typedefs like aaudio_sample_rate_t
Removed use of handles. Just pass back opaque pointers.
Simplified gettersi in Stream.
Removed getters from Builder.
Update libaaudio.map.txt

Test: CTS test_aaudio.cpp
Change-Id: I63eaec3e5a8ecc516cfc1f950f4b4f54df1bd518
Signed-off-by: Phil Burk <philburk@google.com>
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h
f53e613b3dedab3ecada2c93d8846233c442d129 09-Feb-2017 Phil Burk <philburk@google.com> libaaudio: change name from liboboe

Bug: 34749573
Test: CTS test_aaudio.cpp
Change-Id: I7e2b621488047f0798ca6f2fc00d2b5fed2bf015
Signed-off-by: Phil Burk <philburk@google.com>
/frameworks/av/media/libaaudio/src/utility/AAudioUtilities.h