Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(161)

Side by Side Diff: src/core/SkRasterClip.h

Issue 1893433002: In SkDraw::drawRect, use SkPath for huge rects. Base URL: https://skia.googlesource.com/skia@fixed-assert
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/core/SkDraw.cpp ('k') | src/core/SkRasterClip.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2010 Google Inc. 2 * Copyright 2010 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #ifndef SkRasterClip_DEFINED 8 #ifndef SkRasterClip_DEFINED
9 #define SkRasterClip_DEFINED 9 #define SkRasterClip_DEFINED
10 10
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 51
52 void translate(int dx, int dy, SkRasterClip* dst) const; 52 void translate(int dx, int dy, SkRasterClip* dst) const;
53 void translate(int dx, int dy) { 53 void translate(int dx, int dy) {
54 this->translate(dx, dy, this); 54 this->translate(dx, dy, this);
55 } 55 }
56 56
57 bool quickContains(const SkIRect& rect) const; 57 bool quickContains(const SkIRect& rect) const;
58 bool quickContains(int left, int top, int right, int bottom) const { 58 bool quickContains(int left, int top, int right, int bottom) const {
59 return quickContains(SkIRect::MakeLTRB(left, top, right, bottom)); 59 return quickContains(SkIRect::MakeLTRB(left, top, right, bottom));
60 } 60 }
61 bool quickContains(const SkRect& rect) const;
61 62
62 /** 63 /**
63 * Return true if this region is empty, or if the specified rectangle does 64 * Return true if this region is empty, or if the specified rectangle does
64 * not intersect the region. Returning false is not a guarantee that they 65 * not intersect the region. Returning false is not a guarantee that they
65 * intersect, but returning true is a guarantee that they do not. 66 * intersect, but returning true is a guarantee that they do not.
66 */ 67 */
67 bool quickReject(const SkIRect& rect) const { 68 bool quickReject(const SkIRect& rect) const {
68 return !SkIRect::Intersects(this->getBounds(), rect); 69 return !SkIRect::Intersects(this->getBounds(), rect);
69 } 70 }
71 bool quickReject(const SkRect& rect) const;
70 72
71 // hack for SkCanvas::getTotalClip 73 // hack for SkCanvas::getTotalClip
72 const SkRegion& forceGetBW(); 74 const SkRegion& forceGetBW();
73 75
74 #ifdef SK_DEBUG 76 #ifdef SK_DEBUG
75 void validate() const; 77 void validate() const;
76 #else 78 #else
77 void validate() const {} 79 void validate() const {}
78 #endif 80 #endif
79 81
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 171
170 private: 172 private:
171 SkRegion fBWRgn; 173 SkRegion fBWRgn;
172 SkAAClipBlitter fAABlitter; 174 SkAAClipBlitter fAABlitter;
173 // what we return 175 // what we return
174 const SkRegion* fClipRgn; 176 const SkRegion* fClipRgn;
175 SkBlitter* fBlitter; 177 SkBlitter* fBlitter;
176 }; 178 };
177 179
178 #endif 180 #endif
OLDNEW
« no previous file with comments | « src/core/SkDraw.cpp ('k') | src/core/SkRasterClip.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698