Index: skia/ext/analysis_canvas.cc |
diff --git a/skia/ext/analysis_canvas.cc b/skia/ext/analysis_canvas.cc |
index 74a7c23fd8c2aed515c8218cef63076b2a003703..d8e5b15913a5b7ad7a2179349dce9184c40fba44 100644 |
--- a/skia/ext/analysis_canvas.cc |
+++ b/skia/ext/analysis_canvas.cc |
@@ -171,7 +171,8 @@ void AnalysisDevice::clear(SkColor color) { |
void AnalysisDevice::drawPaint(const SkDraw&, const SkPaint& paint) { |
addBitmapFromPaint(paint); |
- isSolidColor_ = false; |
+ isSolidColor_ = |
+ (isSolidColor_ && isSolidColorPaint(paint) && paint.getColor() == color_); |
isTransparent_ = false; |
} |
@@ -219,9 +220,12 @@ void AnalysisDevice::drawRect(const SkDraw& draw, const SkRect& rect, |
// - We're not in "forced not solid" mode |
// - Paint is solid color |
// - The quad is a full tile quad |
+ // - The exception is if the tile is already solid tile, |
+ // and we're drawing the same solid color paint then |
+ // the tile remains solid. |
Tom Hudson
2013/04/30 09:43:59
This could be a different CL? But nice catch! Does
vmpstr
2013/04/30 17:06:23
This shows up on low res tiles. However, with the
|
if (!isForcedNotSolid_ && |
isSolidColorPaint(paint) && |
- doesCoverCanvas) { |
+ (doesCoverCanvas || (isSolidColor_ && paint.getColor() == color_))) { |
isSolidColor_ = true; |
color_ = paint.getColor(); |
hasText_ = false; |