diff options
author | Andreas Huber <andih@google.com> | 2011-03-28 08:34:06 -0700 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2011-03-28 08:34:06 -0700 |
commit | b1d3d37c7990d22d0659e4c8c9aac56d4c09b6ea (patch) | |
tree | c994f002faa5273a8484fa7a5090768a631592a4 | |
parent | 000cca99e085be1aa46df44109b37a84af58e7c8 (diff) | |
parent | 3979f08f59ab2905510a439bae32b92ae21cfddf (diff) | |
download | frameworks_av-b1d3d37c7990d22d0659e4c8c9aac56d4c09b6ea.zip frameworks_av-b1d3d37c7990d22d0659e4c8c9aac56d4c09b6ea.tar.gz frameworks_av-b1d3d37c7990d22d0659e4c8c9aac56d4c09b6ea.tar.bz2 |
am a4a81aef: am e7cedad2: am 2edbdcc6: Merge "After a seek there\'s a brief period where audio time isn\'t reestablished." into honeycomb-mr1
* commit 'a4a81aef39b15649bda146476d98f23ac554887f':
After a seek there's a brief period where audio time isn't reestablished.
-rw-r--r-- | media/libstagefright/AudioPlayer.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/media/libstagefright/AudioPlayer.cpp b/media/libstagefright/AudioPlayer.cpp index 07f250a..162d2e6 100644 --- a/media/libstagefright/AudioPlayer.cpp +++ b/media/libstagefright/AudioPlayer.cpp @@ -452,6 +452,10 @@ int64_t AudioPlayer::getMediaTimeUs() { Mutex::Autolock autoLock(mLock); if (mPositionTimeMediaUs < 0 || mPositionTimeRealUs < 0) { + if (mSeeking) { + return mSeekTimeUs; + } + return 0; } @@ -477,6 +481,7 @@ status_t AudioPlayer::seekTo(int64_t time_us) { Mutex::Autolock autoLock(mLock); mSeeking = true; + mPositionTimeRealUs = mPositionTimeMediaUs = -1; mReachedEOS = false; mSeekTimeUs = time_us; |