diff options
author | Steven Thomas <steventhomas@google.com> | 2020-08-21 16:56:08 -0700 |
---|---|---|
committer | Ady Abraham <adyabr@google.com> | 2020-09-16 22:58:39 -0700 |
commit | 6fabb5aa1772cc8cb126a0341c28942c4f0e164b (patch) | |
tree | 4cd15ae838ea41021ee849dba473b2d95a381921 /libs/hwui/renderthread/RenderThread.cpp | |
parent | e78c0050bb17e300940519ff5c9dce2fbeec65ad (diff) |
Shared timeline plumbing
Add plumbing to get shared timeline data from Surface Flinger to HWUI
and back.
Bug: 162890382
Bug: 162888881
Bug: 162890407
Test: manual using ALOG messages in SF
Change-Id: I85c5eb56d2fa933889518854e7b79b1e65e29af3
Diffstat (limited to 'libs/hwui/renderthread/RenderThread.cpp')
-rw-r--r-- | libs/hwui/renderthread/RenderThread.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libs/hwui/renderthread/RenderThread.cpp b/libs/hwui/renderthread/RenderThread.cpp index 4dcbc4458e97..9371656eda7f 100644 --- a/libs/hwui/renderthread/RenderThread.cpp +++ b/libs/hwui/renderthread/RenderThread.cpp @@ -51,8 +51,10 @@ static JVMAttachHook gOnStartHook = nullptr; void RenderThread::frameCallback(int64_t frameTimeNanos, void* data) { RenderThread* rt = reinterpret_cast<RenderThread*>(data); + int64_t vsyncId = AChoreographer_getVsyncId(rt->mChoreographer); rt->mVsyncRequested = false; - if (rt->timeLord().vsyncReceived(frameTimeNanos) && !rt->mFrameCallbackTaskPending) { + if (rt->timeLord().vsyncReceived(frameTimeNanos, frameTimeNanos, vsyncId) && + !rt->mFrameCallbackTaskPending) { ATRACE_NAME("queue mFrameCallbackTask"); rt->mFrameCallbackTaskPending = true; nsecs_t runAt = (frameTimeNanos + rt->mDispatchFrameDelay); |