From bd6b79b40247aea7bfe13d0831c6c0472df6c636 Mon Sep 17 00:00:00 2001 From: Romain Guy Date: Sat, 26 Jun 2010 00:13:53 -0700 Subject: Add implementations for saveLayerAlpha() and textured rects. Even though there's an implementation for textured rects, drawBitmap() is not hooked up yet as it will require a good texture cache. This method is implemented using FBOs. There's currently an issue either in the driver or in the Canvas renderer that forces the FBO to be fullscreen, which is extremely expensive and yields terrible performance. Change-Id: I148419195e12d45653c60186938aa78c23a68e2c --- libs/hwui/Matrix.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'libs/hwui/Matrix.cpp') diff --git a/libs/hwui/Matrix.cpp b/libs/hwui/Matrix.cpp index c772f003f014..e9c7791677c9 100644 --- a/libs/hwui/Matrix.cpp +++ b/libs/hwui/Matrix.cpp @@ -97,6 +97,14 @@ void Matrix4::copyTo(float* v) const { memcpy(v, data, sizeof(data)); } +float Matrix4::getTranslateX() { + return data[12]; +} + +float Matrix4::getTranslateY() { + return data[13]; +} + void Matrix4::loadTranslate(float x, float y, float z) { loadIdentity(); data[12] = x; -- cgit v1.2.3-59-g8ed1b