Index: src/core/SkCanvas.cpp |
diff --git a/src/core/SkCanvas.cpp b/src/core/SkCanvas.cpp |
index c7a9dc72f299e75347298965966dc7554cb80c84..7102c3385514a61d28ce3946a39a74ec4c920035 100644 |
--- a/src/core/SkCanvas.cpp |
+++ b/src/core/SkCanvas.cpp |
@@ -2036,6 +2036,18 @@ void SkCanvas::legacy_drawBitmapRect(const SkBitmap& bitmap, const SkRect* src, |
} |
} |
+void SkCanvas::temporary_internal_describeTopLayer(SkMatrix* matrix, SkIRect* clip_bounds) { |
+ SkIRect layer_bounds = this->getTopLayerBounds(); |
+ if (matrix) { |
+ *matrix = this->getTotalMatrix(); |
+ matrix->preTranslate(-layer_bounds.left(), -layer_bounds.top()); |
+ } |
+ if (clip_bounds) { |
+ this->getClipDeviceBounds(clip_bounds); |
+ clip_bounds->offset(-layer_bounds.left(), -layer_bounds.top()); |
+ } |
+} |
+ |
////////////////////////////////////////////////////////////////////////////// |
// These are the virtual drawing methods |
////////////////////////////////////////////////////////////////////////////// |