Loading libs/hwui/Matrix.cpp +4 −0 Original line number Diff line number Diff line Loading @@ -67,6 +67,10 @@ bool Matrix4::isPureTranslate() { ALMOST_EQUAL(data[kScaleX], 1.0f) && ALMOST_EQUAL(data[kScaleY], 1.0f); } bool Matrix4::isSimple() { return mSimpleMatrix; } void Matrix4::load(const float* v) { memcpy(data, v, sizeof(data)); mSimpleMatrix = false; Loading libs/hwui/Matrix.h +1 −0 Original line number Diff line number Diff line Loading @@ -111,6 +111,7 @@ public: } bool isPureTranslate(); bool isSimple(); bool changesBounds(); Loading libs/hwui/OpenGLRenderer.cpp +2 −3 Original line number Diff line number Diff line Loading @@ -1478,8 +1478,7 @@ void OpenGLRenderer::drawPatch(SkBitmap* bitmap, const int32_t* xDivs, const int * within that boundary region and how far into the region it is. */ void OpenGLRenderer::drawAARect(float left, float top, float right, float bottom, int color, SkXfermode::Mode mode) { int color, SkXfermode::Mode mode) { float inverseScaleX = 1.0f; float inverseScaleY = 1.0f; // The quad that we use needs to account for scaling. Loading Loading @@ -1935,7 +1934,7 @@ void OpenGLRenderer::drawRect(float left, float top, float right, float bottom, } int color = p->getColor(); if (p->isAntiAlias()) { if (p->isAntiAlias() && !mSnapshot->transform->isSimple()) { drawAARect(left, top, right, bottom, color, mode); } else { drawColorRect(left, top, right, bottom, color, mode); Loading Loading
libs/hwui/Matrix.cpp +4 −0 Original line number Diff line number Diff line Loading @@ -67,6 +67,10 @@ bool Matrix4::isPureTranslate() { ALMOST_EQUAL(data[kScaleX], 1.0f) && ALMOST_EQUAL(data[kScaleY], 1.0f); } bool Matrix4::isSimple() { return mSimpleMatrix; } void Matrix4::load(const float* v) { memcpy(data, v, sizeof(data)); mSimpleMatrix = false; Loading
libs/hwui/Matrix.h +1 −0 Original line number Diff line number Diff line Loading @@ -111,6 +111,7 @@ public: } bool isPureTranslate(); bool isSimple(); bool changesBounds(); Loading
libs/hwui/OpenGLRenderer.cpp +2 −3 Original line number Diff line number Diff line Loading @@ -1478,8 +1478,7 @@ void OpenGLRenderer::drawPatch(SkBitmap* bitmap, const int32_t* xDivs, const int * within that boundary region and how far into the region it is. */ void OpenGLRenderer::drawAARect(float left, float top, float right, float bottom, int color, SkXfermode::Mode mode) { int color, SkXfermode::Mode mode) { float inverseScaleX = 1.0f; float inverseScaleY = 1.0f; // The quad that we use needs to account for scaling. Loading Loading @@ -1935,7 +1934,7 @@ void OpenGLRenderer::drawRect(float left, float top, float right, float bottom, } int color = p->getColor(); if (p->isAntiAlias()) { if (p->isAntiAlias() && !mSnapshot->transform->isSimple()) { drawAARect(left, top, right, bottom, color, mode); } else { drawColorRect(left, top, right, bottom, color, mode); Loading