| OLD | NEW | 
|---|
| 1 /* | 1 /* | 
| 2  * Copyright 2014 Google Inc. | 2  * Copyright 2014 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 SkPathOpsTSect_DEFINED | 7 #ifndef SkPathOpsTSect_DEFINED | 
| 8 #define SkPathOpsTSect_DEFINED | 8 #define SkPathOpsTSect_DEFINED | 
| 9 | 9 | 
| 10 #include "SkChunkAlloc.h" | 10 #include "SkChunkAlloc.h" | 
| (...skipping 974 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 985             largest = test; | 985             largest = test; | 
| 986             lCollapsed = test->fCollapsed; | 986             lCollapsed = test->fCollapsed; | 
| 987         } | 987         } | 
| 988     } | 988     } | 
| 989     return largest; | 989     return largest; | 
| 990 } | 990 } | 
| 991 | 991 | 
| 992 template<typename TCurve, typename OppCurve> | 992 template<typename TCurve, typename OppCurve> | 
| 993 bool SkTSect<TCurve, OppCurve>::coincidentCheck(SkTSect<OppCurve, TCurve>* sect2
      ) { | 993 bool SkTSect<TCurve, OppCurve>::coincidentCheck(SkTSect<OppCurve, TCurve>* sect2
      ) { | 
| 994     SkTSpan<TCurve, OppCurve>* first = fHead; | 994     SkTSpan<TCurve, OppCurve>* first = fHead; | 
|  | 995     if (!first) { | 
|  | 996         return false; | 
|  | 997     } | 
| 995     SkTSpan<TCurve, OppCurve>* last, * next; | 998     SkTSpan<TCurve, OppCurve>* last, * next; | 
| 996     do { | 999     do { | 
| 997         int consecutive = this->countConsecutiveSpans(first, &last); | 1000         int consecutive = this->countConsecutiveSpans(first, &last); | 
| 998         next = last->fNext; | 1001         next = last->fNext; | 
| 999         if (consecutive < COINCIDENT_SPAN_COUNT) { | 1002         if (consecutive < COINCIDENT_SPAN_COUNT) { | 
| 1000             continue; | 1003             continue; | 
| 1001         } | 1004         } | 
| 1002         this->validate(); | 1005         this->validate(); | 
| 1003         sect2->validate(); | 1006         sect2->validate(); | 
| 1004         this->computePerpendiculars(sect2, first, last); | 1007         this->computePerpendiculars(sect2, first, last); | 
| (...skipping 1391 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 2396             --last; | 2399             --last; | 
| 2397         } else { | 2400         } else { | 
| 2398             intersections->setCoincident(index++); | 2401             intersections->setCoincident(index++); | 
| 2399         } | 2402         } | 
| 2400         intersections->setCoincident(index); | 2403         intersections->setCoincident(index); | 
| 2401     } | 2404     } | 
| 2402     SkOPOBJASSERT(intersections, intersections->used() <= TCurve::kMaxIntersecti
      ons); | 2405     SkOPOBJASSERT(intersections, intersections->used() <= TCurve::kMaxIntersecti
      ons); | 
| 2403 } | 2406 } | 
| 2404 | 2407 | 
| 2405 #endif | 2408 #endif | 
| OLD | NEW | 
|---|