diff options
author | Haynes Mathew George <hgeorge@codeaurora.org> | 2014-01-08 13:59:53 -0800 |
---|---|---|
committer | Eric Laurent <elaurent@google.com> | 2014-03-06 11:38:38 -0800 |
commit | 7064fd2dcdfeafea53cd5a992bb78c413542f29f (patch) | |
tree | eb8961194a192128c7db06f5c0de50f9a72b93cd /include/media/AudioTrack.h | |
parent | 48588bdd9ec1102a5e96b9033d1ed8b8d6a3b3ba (diff) | |
download | frameworks_av-7064fd2dcdfeafea53cd5a992bb78c413542f29f.zip frameworks_av-7064fd2dcdfeafea53cd5a992bb78c413542f29f.tar.gz frameworks_av-7064fd2dcdfeafea53cd5a992bb78c413542f29f.tar.bz2 |
AudioTrack: When paused, return cached playback position
An offload output can be re-used between two audio tracks having
the same configuration. A timestamp query for a paused track
while the other is running would return an incorrect time.
To fix this, cache the playback position on a pause() and return
this time when requested until the track is resumed.
Bug: 12826612.
Change-Id: I324112ea9827e52fff53ef44cd8513c8d85a0bc4
Diffstat (limited to 'include/media/AudioTrack.h')
-rw-r--r-- | include/media/AudioTrack.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/media/AudioTrack.h b/include/media/AudioTrack.h index 7e9d557..7d23d02 100644 --- a/include/media/AudioTrack.h +++ b/include/media/AudioTrack.h @@ -746,6 +746,7 @@ protected: bool mInUnderrun; // whether track is currently in underrun state String8 mName; // server's name for this IAudioTrack + uint32_t mPausedPosition; private: class DeathNotifier : public IBinder::DeathRecipient { |