Loading libs/hwui/ProgramCache.cpp +3 −1 Original line number Diff line number Diff line Loading @@ -327,8 +327,10 @@ const char* gFS_Main_ApplyColorOp[3] = { // None "", // Matrix " fragColor.rgb /= (fragColor.a + 0.0019);\n" // un-premultiply " fragColor *= colorMatrix;\n" " fragColor += colorMatrixVector;\n", " fragColor += colorMatrixVector;\n" " fragColor.rgb *= (fragColor.a + 0.0019);\n", // re-premultiply // PorterDuff " fragColor = blendColors(colorBlend, fragColor);\n" }; Loading libs/hwui/Renderer.h +2 −0 Original line number Diff line number Diff line Loading @@ -70,6 +70,7 @@ public: // TODO: move to a method on android:Paint static inline bool paintWillNotDraw(const SkPaint& paint) { return paint.getAlpha() == 0 && !paint.getColorFilter() && getXfermode(paint.getXfermode()) != SkXfermode::kClear_Mode; } Loading @@ -77,6 +78,7 @@ public: static inline bool paintWillNotDrawText(const SkPaint& paint) { return paint.getAlpha() == 0 && paint.getLooper() == NULL && !paint.getColorFilter() && getXfermode(paint.getXfermode()) == SkXfermode::kSrcOver_Mode; } // ---------------------------------------------------------------------------- Loading Loading
libs/hwui/ProgramCache.cpp +3 −1 Original line number Diff line number Diff line Loading @@ -327,8 +327,10 @@ const char* gFS_Main_ApplyColorOp[3] = { // None "", // Matrix " fragColor.rgb /= (fragColor.a + 0.0019);\n" // un-premultiply " fragColor *= colorMatrix;\n" " fragColor += colorMatrixVector;\n", " fragColor += colorMatrixVector;\n" " fragColor.rgb *= (fragColor.a + 0.0019);\n", // re-premultiply // PorterDuff " fragColor = blendColors(colorBlend, fragColor);\n" }; Loading
libs/hwui/Renderer.h +2 −0 Original line number Diff line number Diff line Loading @@ -70,6 +70,7 @@ public: // TODO: move to a method on android:Paint static inline bool paintWillNotDraw(const SkPaint& paint) { return paint.getAlpha() == 0 && !paint.getColorFilter() && getXfermode(paint.getXfermode()) != SkXfermode::kClear_Mode; } Loading @@ -77,6 +78,7 @@ public: static inline bool paintWillNotDrawText(const SkPaint& paint) { return paint.getAlpha() == 0 && paint.getLooper() == NULL && !paint.getColorFilter() && getXfermode(paint.getXfermode()) == SkXfermode::kSrcOver_Mode; } // ---------------------------------------------------------------------------- Loading