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

Unified Diff: src/pathops/SkAddIntersections.cpp

Issue 2273293004: path ops stream-lining (Closed)
Patch Set: remove commented out code Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/pathops/SkOpCoincidence.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/pathops/SkAddIntersections.cpp
diff --git a/src/pathops/SkAddIntersections.cpp b/src/pathops/SkAddIntersections.cpp
index a6cebca4b84daa197b6ea9b43a753766a96f19fe..bdc7ae256556b818cc4f00025d7ecab66cbeb777 100644
--- a/src/pathops/SkAddIntersections.cpp
+++ b/src/pathops/SkAddIntersections.cpp
@@ -505,11 +505,12 @@ bool AddIntersectTs(SkOpContour* test, SkOpContour* next, SkOpCoincidence* coinc
SkASSERT(ts[0][pt] >= 0 && ts[0][pt] <= 1);
SkASSERT(ts[1][pt] >= 0 && ts[1][pt] <= 1);
wt.segment()->debugValidate();
- SkOpPtT* testTAt = wt.segment()->addT(ts[swap][pt], nullptr);
+ SkOpPtT* testTAt = wt.segment()->addT(ts[swap][pt]);
wn.segment()->debugValidate();
- SkOpPtT* nextTAt = wn.segment()->addT(ts[!swap][pt], nullptr);
- if (testTAt->addOpp(nextTAt)) {
- testTAt->span()->checkForCollapsedCoincidence();
+ SkOpPtT* nextTAt = wn.segment()->addT(ts[!swap][pt]);
+ SkOpPtT* oppPrev = testTAt->oppPrev(nextTAt);
+ if (oppPrev) {
+ testTAt->addOpp(nextTAt, oppPrev);
}
if (testTAt->fPt != nextTAt->fPt) {
testTAt->span()->unaligned();
« no previous file with comments | « no previous file | src/pathops/SkOpCoincidence.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698