aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/gpu/GrClip.h
diff options
context:
space:
mode:
authorGravatar robertphillips <robertphillips@google.com>2016-03-02 08:43:13 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2016-03-02 08:43:13 -0800
commit86c60758e9e4f9e203d7462cb22b2a245a0f51bd (patch)
tree0cc77d90e91bf61a381878afbdce7022b89524ff /include/gpu/GrClip.h
parent46b301d2222b60dd5ab495b917dea163e8be94ef (diff)
Begin weaning GrClipMaskManager off of GrDrawTarget (take 2)
Diffstat (limited to 'include/gpu/GrClip.h')
-rw-r--r--include/gpu/GrClip.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/gpu/GrClip.h b/include/gpu/GrClip.h
index cf6e65c976..fd8b970e39 100644
--- a/include/gpu/GrClip.h
+++ b/include/gpu/GrClip.h
@@ -114,6 +114,13 @@ public:
}
}
+ void setIRect(const SkIRect& irect) {
+ this->reset();
+ fClipType = kIRect_ClipType;
+ fOrigin.setZero();
+ fClip.fIRect = irect;
+ }
+
const SkIRect& irect() const {
SkASSERT(kIRect_ClipType == fClipType);
return fClip.fIRect;