summaryrefslogtreecommitdiff
path: root/libs/hwui/Program.cpp
diff options
context:
space:
mode:
authorRomain Guy <romainguy@google.com>2013-06-11 16:19:24 -0700
committerRomain Guy <romainguy@google.com>2013-06-11 17:14:59 -0700
commit4c2547fa9244e78115cde0a259291053108c3dc7 (patch)
tree4337937e216918e4febe861daa7ef093b99aff03 /libs/hwui/Program.cpp
parentfadd2081443dd2f59f8e8143256a34b7485fe72e (diff)
Avoid 9patch cache lookups when possible
This optimization saves up to 0.3ms per frame on the Play Store's front page, on a Nexus 4 device. Change-Id: Iaa4ef33c6e3b37e175efd5b9eea9ef59b43f14f3
Diffstat (limited to 'libs/hwui/Program.cpp')
-rw-r--r--libs/hwui/Program.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/libs/hwui/Program.cpp b/libs/hwui/Program.cpp
index c127d684be32..9e4670e62dcd 100644
--- a/libs/hwui/Program.cpp
+++ b/libs/hwui/Program.cpp
@@ -172,7 +172,7 @@ void Program::set(const mat4& projectionMatrix, const mat4& modelViewMatrix,
// up and to the left.
// This offset value is based on an assumption that some hardware may use as
// little as 12.4 precision, so we offset by slightly more than 1/16.
- p.translate(.065, .065, 0);
+ p.translate(.065, .065);
glUniformMatrix4fv(projection, 1, GL_FALSE, &p.data[0]);
}
mProjection = projectionMatrix;