Mark unstructured grids
| 631 | |
| 632 | // Mark unstructured grids |
| 633 | int UnstructuredGridExecute(vtkDataSet* dsInput, const unsigned char* ghosts, |
| 634 | unsigned char* bPoints, unsigned char* bCells, vtkIdType* bFaces, vtkMarkBoundaryFilter* self) |
| 635 | { |
| 636 | vtkUnstructuredGrid* input = static_cast<vtkUnstructuredGrid*>(dsInput); |
| 637 | vtkCellArray* connectivity = input->GetCells(); |
| 638 | |
| 639 | if (connectivity == nullptr) |
| 640 | { |
| 641 | return 0; |
| 642 | } |
| 643 | |
| 644 | vtkIdType numCells = input->GetNumberOfCells(); |
| 645 | |
| 646 | // Make sure links are built since link building is not thread safe. |
| 647 | input->BuildLinks(); |
| 648 | |
| 649 | // Perform the threaded boundary marking. |
| 650 | MarkUGrid mark(input, ghosts, bPoints, bCells, bFaces, self); |
| 651 | vtkSMPTools::For(0, numCells, mark); |
| 652 | |
| 653 | return 1; |
| 654 | } |
| 655 | |
| 656 | struct MarkStructured : public MarkCellBoundary |
| 657 | { |
no test coverage detected