| Index: src/core/SkPath.cpp
|
| diff --git a/src/core/SkPath.cpp b/src/core/SkPath.cpp
|
| index 6692a0f94ed134b996b0b5ff28cb8a2e7f0bfb03..442b95b90ae865b25af16ea2917d3e032f1e953c 100644
|
| --- a/src/core/SkPath.cpp
|
| +++ b/src/core/SkPath.cpp
|
| @@ -504,6 +504,14 @@ bool SkPath::isRectContour(bool allowPartial, int* currVerb, const SkPoint** pts
|
| return result;
|
| }
|
|
|
| +SkPath::PathAsRect SkPath::asRect(Direction* direction) const {
|
| + SK_COMPILE_ASSERT(0 == kNone_PathAsRect, path_as_rect_mismatch);
|
| + SK_COMPILE_ASSERT(1 == kStroke_PathAsRect, path_as_rect_mismatch);
|
| + SK_COMPILE_ASSERT(2 == kFill_PathAsRect, path_as_rect_mismatch);
|
| + bool isClosed = false;
|
| + return (PathAsRect) (isRect(&isClosed, direction) + isClosed);
|
| +}
|
| +
|
| bool SkPath::isRect(SkRect* rect) const {
|
| SkDEBUGCODE(this->validate();)
|
| int currVerb = 0;
|
|
|