|
1 | 1 | /* |
2 | | -Copyright 2012-2023 Ronald Römer |
| 2 | +Copyright 2012-2024 Ronald Römer |
3 | 3 |
|
4 | 4 | Licensed under the Apache License, Version 2.0 (the "License"); |
5 | 5 | you may not use this file except in compliance with the License. |
@@ -1831,7 +1831,7 @@ void vtkPolyDataBooleanFilter::RestoreOrigPoints (vtkPolyData *pd, PolyStripsTyp |
1831 | 1831 | std::cout << "RestoreOrigPoints()" << std::endl; |
1832 | 1832 | #endif |
1833 | 1833 |
|
1834 | | - pd->BuildLinks(); |
| 1834 | + pd->DeleteLinks(); pd->BuildLinks(); |
1835 | 1835 |
|
1836 | 1836 | vtkKdTreePointLocator *loc = vtkKdTreePointLocator::New(); |
1837 | 1837 | loc->SetDataSet(pd); |
@@ -1873,7 +1873,7 @@ void vtkPolyDataBooleanFilter::DisjoinPolys (vtkPolyData *pd, PolyStripsType &po |
1873 | 1873 | std::cout << "DisjoinPolys()" << std::endl; |
1874 | 1874 | #endif |
1875 | 1875 |
|
1876 | | - pd->BuildLinks(); |
| 1876 | + pd->DeleteLinks(); pd->BuildLinks(); |
1877 | 1877 |
|
1878 | 1878 | vtkKdTreePointLocator *loc = vtkKdTreePointLocator::New(); |
1879 | 1879 | loc->SetDataSet(pd); |
@@ -2093,7 +2093,7 @@ void vtkPolyDataBooleanFilter::AddAdjacentPoints (vtkPolyData *pd, vtkIdTypeArra |
2093 | 2093 | std::cout << "AddAdjacentPoints()" << std::endl; |
2094 | 2094 | #endif |
2095 | 2095 |
|
2096 | | - pd->BuildLinks(); |
| 2096 | + pd->DeleteLinks(); pd->BuildLinks(); |
2097 | 2097 |
|
2098 | 2098 | vtkIdTypeArray *origCellIds = vtkIdTypeArray::SafeDownCast(pd->GetCellData()->GetScalars("OrigCellIds")); |
2099 | 2099 |
|
@@ -2282,9 +2282,9 @@ void vtkPolyDataBooleanFilter::MergePoints (vtkPolyData *pd, PolyStripsType &pol |
2282 | 2282 | #endif |
2283 | 2283 |
|
2284 | 2284 | pd->BuildCells(); |
2285 | | - pd->BuildLinks(); |
| 2285 | + pd->DeleteLinks(); pd->BuildLinks(); |
2286 | 2286 |
|
2287 | | - contLines->BuildLinks(); |
| 2287 | + contLines->DeleteLinks(); contLines->BuildLinks(); |
2288 | 2288 |
|
2289 | 2289 | auto loc = vtkSmartPointer<vtkKdTreePointLocator>::New(); |
2290 | 2290 | loc->SetDataSet(pd); |
@@ -2739,8 +2739,8 @@ bool vtkPolyDataBooleanFilter::CombineRegions () { |
2739 | 2739 | plB->SetDataSet(pdB); |
2740 | 2740 | plB->BuildLocator(); |
2741 | 2741 |
|
2742 | | - pdA->BuildLinks(); |
2743 | | - pdB->BuildLinks(); |
| 2742 | + pdA->DeleteLinks(); pdA->BuildLinks(); |
| 2743 | + pdB->DeleteLinks(); pdB->BuildLinks(); |
2744 | 2744 |
|
2745 | 2745 | vtkIdTypeArray *scalarsA = vtkIdTypeArray::SafeDownCast(pdA->GetPointData()->GetScalars()); |
2746 | 2746 | vtkIdTypeArray *scalarsB = vtkIdTypeArray::SafeDownCast(pdB->GetPointData()->GetScalars()); |
|
0 commit comments