summaryrefslogtreecommitdiffstats
path: root/libs/gui/include
diff options
context:
space:
mode:
authorAdy Abraham <adyabr@google.com>2019-04-29 15:40:03 -0700
committerAdy Abraham <adyabr@google.com>2019-04-30 13:09:06 -0700
commitcd1580cb3fe40e225000a56c9b4ee43c0ce0a45d (patch)
treed222bdfd4de314246784a6f02908bbd3e658ab16 /libs/gui/include
parentdde87c4a326d0480aef0420f04c160b9d5d5096e (diff)
downloadandroid_frameworks_native-cd1580cb3fe40e225000a56c9b4ee43c0ce0a45d.tar.gz
android_frameworks_native-cd1580cb3fe40e225000a56c9b4ee43c0ce0a45d.tar.bz2
android_frameworks_native-cd1580cb3fe40e225000a56c9b4ee43c0ce0a45d.zip
SurfaceFlinger: fix deferred transactions for buffers with timestamps
A deferred transaction needs to wait until the buffer is ready to be latched. This means that the buffer needs to be: 1. Done with rendering (fence has signaled) 2. Present timestamp is within the boundary of the next vsync Test: Screen rotation with Chrome Bug: 130785247 Change-Id: I8def1f10ea3d5c253ab14fa3aa4445588fc2ba8b
Diffstat (limited to 'libs/gui/include')
-rw-r--r--libs/gui/include/gui/BufferQueueConsumer.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/libs/gui/include/gui/BufferQueueConsumer.h b/libs/gui/include/gui/BufferQueueConsumer.h
index aa13c0cf1..7db69eca9 100644
--- a/libs/gui/include/gui/BufferQueueConsumer.h
+++ b/libs/gui/include/gui/BufferQueueConsumer.h
@@ -171,6 +171,9 @@ public:
// End functions required for backwards compatibility
+ // Value used to determine if present time is valid.
+ constexpr static int MAX_REASONABLE_NSEC = 1'000'000'000ULL; // 1 second
+
private:
sp<BufferQueueCore> mCore;