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

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

Issue 2321973005: Rewriting path writer (Closed)
Patch Set: revert unneeded test changes Created 4 years, 3 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/pathops/SkOpEdgeBuilder.cpp ('k') | src/pathops/SkOpSegment.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 #ifndef SkOpSegment_DEFINE 7 #ifndef SkOpSegment_DEFINE
8 #define SkOpSegment_DEFINE 8 #define SkOpSegment_DEFINE
9 9
10 #include "SkOpAngle.h" 10 #include "SkOpAngle.h"
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after
261 bool isVertical() const { 261 bool isVertical() const {
262 return fBounds.fLeft == fBounds.fRight; 262 return fBounds.fLeft == fBounds.fRight;
263 } 263 }
264 264
265 bool isVertical(SkOpSpanBase* start, SkOpSpanBase* end) const { 265 bool isVertical(SkOpSpanBase* start, SkOpSpanBase* end) const {
266 return (*CurveIsVertical[fVerb])(fPts, fWeight, start->t(), end->t()); 266 return (*CurveIsVertical[fVerb])(fPts, fWeight, start->t(), end->t());
267 } 267 }
268 268
269 bool isXor() const; 269 bool isXor() const;
270 270
271 void joinEnds(SkOpSegment* start) {
272 fTail.ptT()->addOpp(start->fHead.ptT(), start->fHead.ptT());
273 }
274
271 const SkPoint& lastPt() const { 275 const SkPoint& lastPt() const {
272 return fPts[SkPathOpsVerbToPoints(fVerb)]; 276 return fPts[SkPathOpsVerbToPoints(fVerb)];
273 } 277 }
274 278
275 void markAllDone(); 279 void markAllDone();
276 SkOpSpanBase* markAndChaseDone(SkOpSpanBase* start, SkOpSpanBase* end); 280 SkOpSpanBase* markAndChaseDone(SkOpSpanBase* start, SkOpSpanBase* end);
277 bool markAndChaseWinding(SkOpSpanBase* start, SkOpSpanBase* end, int winding , 281 bool markAndChaseWinding(SkOpSpanBase* start, SkOpSpanBase* end, int winding ,
278 SkOpSpanBase** lastPtr); 282 SkOpSpanBase** lastPtr);
279 bool markAndChaseWinding(SkOpSpanBase* start, SkOpSpanBase* end, int winding , 283 bool markAndChaseWinding(SkOpSpanBase* start, SkOpSpanBase* end, int winding ,
280 int oppWinding, SkOpSpanBase** lastPtr); 284 int oppWinding, SkOpSpanBase** lastPtr);
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after
451 mutable SkScalar fDebugBaseMin; // if > 0, the 1st t value in this seg vis- a-vis the ref seg 455 mutable SkScalar fDebugBaseMin; // if > 0, the 1st t value in this seg vis- a-vis the ref seg
452 mutable SkScalar fDebugBaseMax; 456 mutable SkScalar fDebugBaseMax;
453 mutable int fDebugLastIndex; 457 mutable int fDebugLastIndex;
454 mutable SkScalar fDebugLastMin; // if > 0, the last t -- next t val - base has same sign 458 mutable SkScalar fDebugLastMin; // if > 0, the last t -- next t val - base has same sign
455 mutable SkScalar fDebugLastMax; 459 mutable SkScalar fDebugLastMax;
456 #endif 460 #endif
457 SkDEBUGCODE(int fID); 461 SkDEBUGCODE(int fID);
458 }; 462 };
459 463
460 #endif 464 #endif
OLDNEW
« no previous file with comments | « src/pathops/SkOpEdgeBuilder.cpp ('k') | src/pathops/SkOpSegment.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698