diff options
author | Andreas Huber <andih@google.com> | 2011-01-04 10:37:30 -0800 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2011-01-04 10:37:30 -0800 |
commit | 08a4186b1f0ca71aac94a24c1dbbdc0a84b8c705 (patch) | |
tree | 1254b55fc57d6f0da04bb07451c2b8e4dc421662 /media | |
parent | ac98e408973219fa9ac628e3c8597c01688fa49d (diff) | |
parent | 90c656574175bd54ed8d258f406f158177e5e91c (diff) | |
download | frameworks_base-08a4186b1f0ca71aac94a24c1dbbdc0a84b8c705.zip frameworks_base-08a4186b1f0ca71aac94a24c1dbbdc0a84b8c705.tar.gz frameworks_base-08a4186b1f0ca71aac94a24c1dbbdc0a84b8c705.tar.bz2 |
Merge "Make AwesomePlayer's reset process more verbose to track down ANRs."
Diffstat (limited to 'media')
-rw-r--r-- | media/libstagefright/AwesomePlayer.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/media/libstagefright/AwesomePlayer.cpp b/media/libstagefright/AwesomePlayer.cpp index d1525cf..b350daf 100644 --- a/media/libstagefright/AwesomePlayer.cpp +++ b/media/libstagefright/AwesomePlayer.cpp @@ -357,11 +357,15 @@ status_t AwesomePlayer::setDataSource_l(const sp<MediaExtractor> &extractor) { } void AwesomePlayer::reset() { + LOGI("reset"); + Mutex::Autolock autoLock(mLock); reset_l(); } void AwesomePlayer::reset_l() { + LOGI("reset_l"); + if (mDecryptHandle != NULL) { mDrmManagerClient->setPlaybackStatus(mDecryptHandle, Playback::STOP, 0); @@ -384,6 +388,10 @@ void AwesomePlayer::reset_l() { } } + if (mFlags & PREPARING) { + LOGI("waiting until preparation is completes."); + } + while (mFlags & PREPARING) { mPreparedCondition.wait(mLock); } @@ -407,6 +415,8 @@ void AwesomePlayer::reset_l() { } mAudioSource.clear(); + LOGI("audio source cleared"); + mTimeSource = NULL; delete mAudioPlayer; @@ -447,6 +457,8 @@ void AwesomePlayer::reset_l() { IPCThreadState::self()->flushCommands(); } + LOGI("video source cleared"); + mDurationUs = -1; mFlags = 0; mExtractorFlags = 0; @@ -463,6 +475,8 @@ void AwesomePlayer::reset_l() { mFileSource.clear(); mBitrate = -1; + + LOGI("reset_l completed"); } void AwesomePlayer::notifyListener_l(int msg, int ext1, int ext2) { |