| Index: third_party/WebKit/Source/modules/canvas2d/ClipList.cpp
|
| diff --git a/third_party/WebKit/Source/modules/canvas2d/ClipList.cpp b/third_party/WebKit/Source/modules/canvas2d/ClipList.cpp
|
| index 427a26a9c9ce37a81a95c97965c249be2790aa66..7443df76139ab1d397f736ea4ea94cd9e9e761b8 100644
|
| --- a/third_party/WebKit/Source/modules/canvas2d/ClipList.cpp
|
| +++ b/third_party/WebKit/Source/modules/canvas2d/ClipList.cpp
|
| @@ -6,6 +6,7 @@
|
|
|
| #include "platform/transforms/AffineTransform.h"
|
| #include "third_party/skia/include/core/SkCanvas.h"
|
| +#include "third_party/skia/include/pathops/SkPathOps.h"
|
|
|
| namespace blink {
|
|
|
| @@ -27,6 +28,15 @@ void ClipList::playback(SkCanvas* canvas) const
|
| }
|
| }
|
|
|
| +SkPath ClipList::intersectPathWithClip(const SkPath& path) const
|
| +{
|
| + SkPath total = path;
|
| + for (const ClipOp* it = m_clipList.begin(); it < m_clipList.end(); it++) {
|
| + Op(total, it->m_path, SkPathOp::kIntersect_SkPathOp, &total);
|
| + }
|
| + return total;
|
| +}
|
| +
|
| ClipList::ClipOp::ClipOp()
|
| : m_antiAliasingMode(AntiAliased)
|
| { }
|
|
|