diff options
author | 2019-08-22 19:20:41 -0700 | |
---|---|---|
committer | 2019-09-06 11:44:42 -0700 | |
commit | 8d0c5bd2006118af9d27813b608f35ce901695c9 (patch) | |
tree | d84e6a3f7992ac61afdd6b9ace694fcb8cf6c02d | |
parent | 7ea41b6975b0471ed31d7b634381d93c9aed44ef (diff) |
[HWUI] hook in ANativeWindow_getLastDequeueStartTime
Bug: 137012798
Test: builds
Change-Id: I37fd2a7c40398053082f606f0a085db0a239e2e0
-rw-r--r-- | libs/hwui/renderthread/CanvasContext.cpp | 2 | ||||
-rw-r--r-- | libs/hwui/renderthread/ReliableSurface.cpp | 2 | ||||
-rw-r--r-- | libs/hwui/renderthread/ReliableSurface.h | 4 |
3 files changed, 3 insertions, 5 deletions
diff --git a/libs/hwui/renderthread/CanvasContext.cpp b/libs/hwui/renderthread/CanvasContext.cpp index a0c5e6315cab..b5ef8f43dfb6 100644 --- a/libs/hwui/renderthread/CanvasContext.cpp +++ b/libs/hwui/renderthread/CanvasContext.cpp @@ -484,7 +484,7 @@ void CanvasContext::draw() { swap.swapCompletedTime = systemTime(SYSTEM_TIME_MONOTONIC); swap.vsyncTime = mRenderThread.timeLord().latestVsync(); if (didDraw) { - nsecs_t dequeueStart = mNativeSurface->getLastDequeueStartTime(); + nsecs_t dequeueStart = ANativeWindow_getLastDequeueStartTime(mNativeSurface.get()); if (dequeueStart < mCurrentFrameInfo->get(FrameInfoIndex::SyncStart)) { // Ignoring dequeue duration as it happened prior to frame render start // and thus is not part of the frame. diff --git a/libs/hwui/renderthread/ReliableSurface.cpp b/libs/hwui/renderthread/ReliableSurface.cpp index a44b80457218..864780fb6ae8 100644 --- a/libs/hwui/renderthread/ReliableSurface.cpp +++ b/libs/hwui/renderthread/ReliableSurface.cpp @@ -308,4 +308,4 @@ int ReliableSurface::hook_perform(ANativeWindow* window, int operation, ...) { return result; } -}; // namespace android::uirenderer::renderthread
\ No newline at end of file +}; // namespace android::uirenderer::renderthread diff --git a/libs/hwui/renderthread/ReliableSurface.h b/libs/hwui/renderthread/ReliableSurface.h index 7f1a0781dd87..0d251b1f10e7 100644 --- a/libs/hwui/renderthread/ReliableSurface.h +++ b/libs/hwui/renderthread/ReliableSurface.h @@ -39,8 +39,6 @@ public: int query(int what, int* value) const { return mSurface->query(what, value); } - nsecs_t getLastDequeueStartTime() const { return mSurface->getLastDequeueStartTime(); } - uint64_t getNextFrameNumber() const { return mSurface->getNextFrameNumber(); } int getAndClearError() { @@ -105,4 +103,4 @@ private: static int hook_queueBuffer_DEPRECATED(ANativeWindow* window, ANativeWindowBuffer* buffer); }; -}; // namespace android::uirenderer::renderthread
\ No newline at end of file +}; // namespace android::uirenderer::renderthread |