Start tracking the CTM while filling the BBH in SkRecordDraw.
Depends on https://codereview.chromium.org/475473002/
BUG=skia:
R=robertphillips@google.com, reed@google.com, mtklein@google.com
Author: mtklein@chromium.org
Review URL: https://codereview.chromium.org/468193003
diff --git a/src/core/SkCanvas.cpp b/src/core/SkCanvas.cpp
index 240dc9c..7e2609b 100644
--- a/src/core/SkCanvas.cpp
+++ b/src/core/SkCanvas.cpp
@@ -895,6 +895,7 @@
if (fMCStack.count() > 1) {
this->willRestore();
this->internalRestore();
+ this->didRestore();
}
}
@@ -2260,7 +2261,7 @@
if (NULL == cubics) {
return;
}
-
+
// Since a patch is always within the convex hull of the control points, we discard it when its
// bounding rectangle is completely outside the current clip.
SkRect bounds;
@@ -2268,7 +2269,7 @@
if (this->quickReject(bounds)) {
return;
}
-
+
this->onDrawPatch(cubics, colors, texCoords, xmode, paint);
}
@@ -2276,11 +2277,11 @@
const SkPoint texCoords[4], SkXfermode* xmode, const SkPaint& paint) {
LOOPER_BEGIN(paint, SkDrawFilter::kPath_Type, NULL)
-
+
while (iter.next()) {
iter.fDevice->drawPatch(iter, cubics, colors, texCoords, xmode, paint);
}
-
+
LOOPER_END
}
@@ -2550,7 +2551,7 @@
} else if (NULL != matrix) {
canvas->save();
}
-
+
if (NULL != matrix) {
canvas->concat(*matrix);
}