commit | 35643ddc689913f5b5f80ceed864470d987bd6cd | [log] [tgz] |
---|---|---|
author | Romain Guy <romainguy@google.com> | Tue Sep 18 15:40:58 2012 -0700 |
committer | Romain Guy <romainguy@google.com> | Tue Sep 18 15:41:16 2012 -0700 |
tree | db2ac0933bc52d1c71aa7d0edfd94c06dcc2cf2a | |
parent | 29d0aa73a099fde05c506857b5d215cde87b78d6 [diff] [blame] |
Minimize state changes when updating layers Change-Id: I407fcc80bd3178f9f09a3b379ceb7f7ce0749e08
diff --git a/libs/hwui/Caches.cpp b/libs/hwui/Caches.cpp index 1de0f9d..edb4c10 100644 --- a/libs/hwui/Caches.cpp +++ b/libs/hwui/Caches.cpp
@@ -378,6 +378,9 @@ if (scissorEnabled && (x != mScissorX || y != mScissorY || width != mScissorWidth || height != mScissorHeight)) { + if (x < 0) x = 0; + if (y < 0) y = 0; + glScissor(x, y, width, height); mScissorX = x;