diff options
author | robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-07-31 19:15:58 +0000 |
---|---|---|
committer | robertphillips@google.com <robertphillips@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81> | 2012-07-31 19:15:58 +0000 |
commit | 641f8b19a6799b6d73ac17b9c2d2f8a5e6f5ad4d (patch) | |
tree | 0c916a12d18cc86343d601811a34229898a8c7f7 /src/core | |
parent | 4b2af9c91d39c2176a32e7ba42a0276dca68034a (diff) |
Replace GrClip with SkClipStack
http://codereview.appspot.com/6449070/
git-svn-id: http://skia.googlecode.com/svn/trunk@4865 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/SkClipStack.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/core/SkClipStack.cpp b/src/core/SkClipStack.cpp index d2c2035bef..e9a02ecbb5 100644 --- a/src/core/SkClipStack.cpp +++ b/src/core/SkClipStack.cpp @@ -381,6 +381,14 @@ SkClipStack::SkClipStack(const SkRect& r) : fDeque(sizeof(Rec)) { } } +SkClipStack::SkClipStack(const SkIRect& r) : fDeque(sizeof(Rec)) { + if (!r.isEmpty()) { + SkRect temp; + temp.set(r); + this->clipDevRect(temp, SkRegion::kReplace_Op, false); + } +} + SkClipStack::~SkClipStack() { reset(); } |