------------------------------------------------------------------------------
| 759 | |
| 760 | //------------------------------------------------------------------------------ |
| 761 | void vtkReebGraph::Implementation::FastArcSimplify( |
| 762 | vtkIdType arcId, int vtkNotUsed(ArcNumber), vtkIdType* vtkNotUsed(arcTable)) |
| 763 | { |
| 764 | // Remove the arc which opens the loop |
| 765 | vtkIdType nodeId0 = this->GetArc(arcId)->NodeId0; |
| 766 | vtkIdType nodeId1 = this->GetArc(arcId)->NodeId1; |
| 767 | |
| 768 | vtkReebArc* A = this->GetArc(arcId); |
| 769 | vtkReebArc* B = nullptr; |
| 770 | int down, middle, up; |
| 771 | |
| 772 | if (historyOn) |
| 773 | { |
| 774 | if (A->ArcDwId0) |
| 775 | { |
| 776 | B = this->GetArc(A->ArcDwId0); |
| 777 | |
| 778 | down = this->GetNode(B->NodeId0)->VertexId; |
| 779 | middle = this->GetNode(A->NodeId0)->VertexId; |
| 780 | up = this->GetNode(B->NodeId1)->VertexId; |
| 781 | |
| 782 | vtkReebCancellation c; |
| 783 | c.removedArcs.emplace_back(middle, up); |
| 784 | c.insertedArcs.emplace_back(down, up); |
| 785 | this->cancellationHistory.push_back(c); |
| 786 | } |
| 787 | if (A->ArcDwId1) |
| 788 | { |
| 789 | B = this->GetArc(A->ArcDwId1); |
| 790 | |
| 791 | down = this->GetNode(B->NodeId0)->VertexId; |
| 792 | middle = this->GetNode(A->NodeId0)->VertexId; |
| 793 | up = this->GetNode(A->NodeId1)->VertexId; |
| 794 | |
| 795 | vtkReebCancellation c; |
| 796 | c.removedArcs.emplace_back(middle, up); |
| 797 | c.insertedArcs.emplace_back(down, up); |
| 798 | this->cancellationHistory.push_back(c); |
| 799 | } |
| 800 | if (A->ArcUpId0) |
| 801 | { |
| 802 | B = this->GetArc(A->ArcUpId0); |
| 803 | |
| 804 | down = this->GetNode(A->NodeId0)->VertexId; |
| 805 | middle = this->GetNode(A->NodeId1)->VertexId; |
| 806 | up = this->GetNode(B->NodeId1)->VertexId; |
| 807 | |
| 808 | vtkReebCancellation c; |
| 809 | c.removedArcs.emplace_back(down, middle); |
| 810 | c.insertedArcs.emplace_back(down, up); |
| 811 | this->cancellationHistory.push_back(c); |
| 812 | } |
| 813 | if (A->ArcUpId1) |
| 814 | { |
| 815 | B = this->GetArc(A->ArcUpId1); |
| 816 | |
| 817 | down = this->GetNode(B->NodeId0)->VertexId; |
| 818 | middle = this->GetNode(A->NodeId1)->VertexId; |
no test coverage detected