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

Side by Side Diff: include/core/SkRRect.h

Issue 193193002: plumbing for GPU fast blur (Closed) Base URL: https://skia.googlesource.com/skia.git@fast_rrect_blur_cpu_plumb
Patch Set: fix indentation issue Created 6 years, 9 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 | « include/core/SkMaskFilter.h ('k') | src/core/SkMaskFilter.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 2012 Google Inc. 2 * Copyright 2012 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 SkRRect_DEFINED 8 #ifndef SkRRect_DEFINED
9 #define SkRRect_DEFINED 9 #define SkRRect_DEFINED
10 10
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 94
95 inline bool isEmpty() const { return kEmpty_Type == this->getType(); } 95 inline bool isEmpty() const { return kEmpty_Type == this->getType(); }
96 inline bool isRect() const { return kRect_Type == this->getType(); } 96 inline bool isRect() const { return kRect_Type == this->getType(); }
97 inline bool isOval() const { return kOval_Type == this->getType(); } 97 inline bool isOval() const { return kOval_Type == this->getType(); }
98 inline bool isSimple() const { return kSimple_Type == this->getType(); } 98 inline bool isSimple() const { return kSimple_Type == this->getType(); }
99 inline bool isSimpleCircular() const { 99 inline bool isSimpleCircular() const {
100 return this->isSimple() && fRadii[0].fX == fRadii[0].fY; 100 return this->isSimple() && fRadii[0].fX == fRadii[0].fY;
101 } 101 }
102 inline bool isComplex() const { return kComplex_Type == this->getType(); } 102 inline bool isComplex() const { return kComplex_Type == this->getType(); }
103 103
104 bool allCornersCircular() const;
105
104 SkScalar width() const { return fRect.width(); } 106 SkScalar width() const { return fRect.width(); }
105 SkScalar height() const { return fRect.height(); } 107 SkScalar height() const { return fRect.height(); }
106 108
107 /** 109 /**
108 * Set this RR to the empty rectangle (0,0,0,0) with 0 x & y radii. 110 * Set this RR to the empty rectangle (0,0,0,0) with 0 x & y radii.
109 */ 111 */
110 void setEmpty() { 112 void setEmpty() {
111 fRect.setEmpty(); 113 fRect.setEmpty();
112 memset(fRadii, 0, sizeof(fRadii)); 114 memset(fRadii, 0, sizeof(fRadii));
113 fType = kEmpty_Type; 115 fType = kEmpty_Type;
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 // uninitialized data 286 // uninitialized data
285 287
286 void computeType() const; 288 void computeType() const;
287 bool checkCornerContainment(SkScalar x, SkScalar y) const; 289 bool checkCornerContainment(SkScalar x, SkScalar y) const;
288 290
289 // to access fRadii directly 291 // to access fRadii directly
290 friend class SkPath; 292 friend class SkPath;
291 }; 293 };
292 294
293 #endif 295 #endif
OLDNEW
« no previous file with comments | « include/core/SkMaskFilter.h ('k') | src/core/SkMaskFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698