OLD | NEW |
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 #include "SkAddIntersections.h" | 7 #include "SkAddIntersections.h" |
8 #include "SkOpCoincidence.h" | 8 #include "SkOpCoincidence.h" |
9 #include "SkPathOpsBounds.h" | 9 #include "SkPathOpsBounds.h" |
10 | 10 |
(...skipping 524 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
535 continue; | 535 continue; |
536 } | 536 } |
537 if (coinPtT[1]->span() == nextTAt->span()) { | 537 if (coinPtT[1]->span() == nextTAt->span()) { |
538 coinIndex = -1; // coincidence span collapsed | 538 coinIndex = -1; // coincidence span collapsed |
539 continue; | 539 continue; |
540 } | 540 } |
541 if (swap) { | 541 if (swap) { |
542 SkTSwap(coinPtT[0], coinPtT[1]); | 542 SkTSwap(coinPtT[0], coinPtT[1]); |
543 SkTSwap(testTAt, nextTAt); | 543 SkTSwap(testTAt, nextTAt); |
544 } | 544 } |
545 SkASSERT(coinPtT[0]->span()->t() < testTAt->span()->t()); | 545 SkASSERT(coincidence->globalState()->debugSkipAssert() |
| 546 || coinPtT[0]->span()->t() < testTAt->span()->t()); |
546 if (coinPtT[0]->span()->deleted()) { | 547 if (coinPtT[0]->span()->deleted()) { |
547 coinIndex = -1; | 548 coinIndex = -1; |
548 continue; | 549 continue; |
549 } | 550 } |
550 if (testTAt->span()->deleted()) { | 551 if (testTAt->span()->deleted()) { |
551 coinIndex = -1; | 552 coinIndex = -1; |
552 continue; | 553 continue; |
553 } | 554 } |
554 coincidence->add(coinPtT[0], testTAt, coinPtT[1], nextTAt); | 555 coincidence->add(coinPtT[0], testTAt, coinPtT[1], nextTAt); |
555 wt.segment()->debugValidate(); | 556 wt.segment()->debugValidate(); |
556 wn.segment()->debugValidate(); | 557 wn.segment()->debugValidate(); |
557 coinIndex = -1; | 558 coinIndex = -1; |
558 } | 559 } |
559 SkASSERT(coinIndex < 0); // expect coincidence to be paired | 560 SkASSERT(coinIndex < 0); // expect coincidence to be paired |
560 } while (wn.advance()); | 561 } while (wn.advance()); |
561 } while (wt.advance()); | 562 } while (wt.advance()); |
562 return true; | 563 return true; |
563 } | 564 } |
OLD | NEW |