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

Side by Side Diff: src/pathops/SkOpAngle.h

Issue 16951017: convert pathops to use SkSTArray where possible. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: pathops use SkTArray Created 7 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « src/pathops/SkDQuadIntersection.cpp ('k') | src/pathops/SkOpContour.h » ('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 #ifndef SkOpAngle_DEFINED 7 #ifndef SkOpAngle_DEFINED
8 #define SkOpAngle_DEFINED 8 #define SkOpAngle_DEFINED
9 9
10 #include "SkLineParameters.h" 10 #include "SkLineParameters.h"
11 #include "SkPath.h" 11 #include "SkPath.h"
12 #include "SkPathOpsCubic.h" 12 #include "SkPathOpsCubic.h"
13 13
14 class SkOpSegment; 14 class SkOpSegment;
15 15
16 // sorting angles 16 // sorting angles
17 // given angles of {dx dy ddx ddy dddx dddy} sort them 17 // given angles of {dx dy ddx ddy dddx dddy} sort them
18 class SkOpAngle { 18 class SkOpAngle {
19 public: 19 public:
20 enum { kStackBasedCount = 8 }; // FIXME: determine what this should be
21
20 bool operator<(const SkOpAngle& rh) const; 22 bool operator<(const SkOpAngle& rh) const;
21 23
22 bool calcSlop(double x, double y, double rx, double ry, bool* result) const; 24 bool calcSlop(double x, double y, double rx, double ry, bool* result) const;
23 25
24 double dx() const { 26 double dx() const {
25 return fTangent1.dx(); 27 return fTangent1.dx();
26 } 28 }
27 29
28 double dy() const { 30 double dy() const {
29 return fTangent1.dy(); 31 return fTangent1.dy();
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
82 // minimum, mark it unorderable. It still can be sorted, which is good enoug h for find-top 84 // minimum, mark it unorderable. It still can be sorted, which is good enoug h for find-top
83 // but can't be ordered, and therefore can't be used to compute winding 85 // but can't be ordered, and therefore can't be used to compute winding
84 bool fUnorderable; 86 bool fUnorderable;
85 mutable bool fUnsortable; // this alone is editable by the less than operat or 87 mutable bool fUnsortable; // this alone is editable by the less than operat or
86 #if DEBUG_ANGLE 88 #if DEBUG_ANGLE
87 int fID; 89 int fID;
88 #endif 90 #endif
89 }; 91 };
90 92
91 #endif 93 #endif
OLDNEW
« no previous file with comments | « src/pathops/SkDQuadIntersection.cpp ('k') | src/pathops/SkOpContour.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698