| 551 | } |
| 552 | |
| 553 | inline Path64 GetCleanPath(OutPt* op) |
| 554 | { |
| 555 | Path64 result; |
| 556 | OutPt* op2 = op; |
| 557 | while (op2->next != op && |
| 558 | ((op2->pt.x == op2->next->pt.x && op2->pt.x == op2->prev->pt.x) || |
| 559 | (op2->pt.y == op2->next->pt.y && op2->pt.y == op2->prev->pt.y))) op2 = op2->next; |
| 560 | result.emplace_back(op2->pt); |
| 561 | OutPt* prevOp = op2; |
| 562 | op2 = op2->next; |
| 563 | while (op2 != op) |
| 564 | { |
| 565 | if ((op2->pt.x != op2->next->pt.x || op2->pt.x != prevOp->pt.x) && |
| 566 | (op2->pt.y != op2->next->pt.y || op2->pt.y != prevOp->pt.y)) |
| 567 | { |
| 568 | result.emplace_back(op2->pt); |
| 569 | prevOp = op2; |
| 570 | } |
| 571 | op2 = op2->next; |
| 572 | } |
| 573 | return result; |
| 574 | } |
| 575 | |
| 576 | inline bool Path2ContainsPath1(OutPt* op1, OutPt* op2) |
| 577 | { |
no outgoing calls
no test coverage detected