commit | ec9a032c2e104ab1e3b5bf73e69dab1408ced0ad | [log] [tgz] |
---|---|---|
author | Eric Laurent <elaurent@google.com> | Wed Aug 28 10:23:01 2013 -0700 |
committer | Eric Laurent <elaurent@google.com> | Wed Aug 28 10:30:08 2013 -0700 |
tree | de4b71e9f43dc9a3a46aec43bc08f910ad5b8127 | |
parent | 3bd3690fb0a423f9d0ba635e8db1c148ac9e93fc [diff] |
AudioTrack: fix unwanted underrun when restarting When restarting an AudioTrack from stopped state, it is necessary to force refresh of mRemainingFrames by processAudioBuffer() as the last write before stop() could be partial. No doing so will lead into unnecessary sleep before filling the non contiguous part of the buffer returned by obtainBuffer() when processAudioBuffer() is executed for the first time after start(). Change-Id: Id703f8dc092a6f07c905eee194054b4a978f979d