diff options
author | Lajos Molnar <lajos@google.com> | 2014-05-01 20:04:45 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2014-05-01 20:04:45 +0000 |
commit | 0c388650722ac53571be21ee04ce342c1c9510c2 (patch) | |
tree | 7fd48b89ea49f4897b27cc1751d7f347c5016fe4 /media | |
parent | 6eafba6bba3a4949cf3807ea39d5c1e969bebc52 (diff) | |
parent | 6fbc1afd36f514f8b8d36ce67f5e69776c690bd2 (diff) | |
download | frameworks_av-0c388650722ac53571be21ee04ce342c1c9510c2.zip frameworks_av-0c388650722ac53571be21ee04ce342c1c9510c2.tar.gz frameworks_av-0c388650722ac53571be21ee04ce342c1c9510c2.tar.bz2 |
Merge "ACodec: add frame render/drop systrace"
Diffstat (limited to 'media')
-rw-r--r-- | media/libstagefright/ACodec.cpp | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/media/libstagefright/ACodec.cpp b/media/libstagefright/ACodec.cpp index dfe6c56..8af61a1 100644 --- a/media/libstagefright/ACodec.cpp +++ b/media/libstagefright/ACodec.cpp @@ -17,6 +17,8 @@ //#define LOG_NDEBUG 0 #define LOG_TAG "ACodec" +#include <utils/Trace.h> + #include <media/stagefright/ACodec.h> #include <binder/MemoryDealer.h> @@ -3416,6 +3418,7 @@ void ACodec::BaseState::onOutputBufferDrained(const sp<AMessage> &msg) { if (mCodec->mNativeWindow != NULL && msg->findInt32("render", &render) && render != 0 && info->mData != NULL && info->mData->size() != 0) { + ATRACE_NAME("render"); // The client wants this buffer to be rendered. status_t err; @@ -3428,6 +3431,10 @@ void ACodec::BaseState::onOutputBufferDrained(const sp<AMessage> &msg) { info->mStatus = BufferInfo::OWNED_BY_US; } } else { + if (mCodec->mNativeWindow != NULL && + (info->mData == NULL || info->mData->size() != 0)) { + ATRACE_NAME("frame-drop"); + } info->mStatus = BufferInfo::OWNED_BY_US; } |