summaryrefslogtreecommitdiff
path: root/libs/hwui/renderthread/CanvasContext.cpp
diff options
context:
space:
mode:
authorChris Craik <ccraik@google.com>2016-09-02 17:41:57 +0000
committerandroid-build-merger <android-build-merger@google.com>2016-09-02 17:41:57 +0000
commitb53c60876aaa287c90750baca026c58bb28f68c2 (patch)
treed18b5fc238a63ba9f55731de7a6594695bd0cc3d /libs/hwui/renderthread/CanvasContext.cpp
parent22eecbe2743f9128a5974661498bbe9205e3b41a (diff)
parent7a14f5aeb95e964052a1b4bf090cc3892f0576c0 (diff)
Wait on frame work fences when frames are dropped am: 06e2e9cf4c
am: 7a14f5aeb9 Change-Id: I9f2159f2f5c8111df0c14e46cc5690cbfab9b7e9
Diffstat (limited to 'libs/hwui/renderthread/CanvasContext.cpp')
-rw-r--r--libs/hwui/renderthread/CanvasContext.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/libs/hwui/renderthread/CanvasContext.cpp b/libs/hwui/renderthread/CanvasContext.cpp
index dcaec428449c..70b9a436dee2 100644
--- a/libs/hwui/renderthread/CanvasContext.cpp
+++ b/libs/hwui/renderthread/CanvasContext.cpp
@@ -633,6 +633,9 @@ void CanvasContext::prepareAndDraw(RenderNode* node) {
prepareTree(info, frameInfo, systemTime(CLOCK_MONOTONIC), node);
if (info.out.canDrawThisFrame) {
draw();
+ } else {
+ // wait on fences so tasks don't overlap next frame
+ waitOnFences();
}
}