------------------------------------------------------------------------------
| 37 | |
| 38 | //------------------------------------------------------------------------------ |
| 39 | vtkRenderedGraphRepresentation* vtkGraphLayoutView::GetGraphRepresentation() |
| 40 | { |
| 41 | vtkRenderedGraphRepresentation* graphRep = nullptr; |
| 42 | for (int i = 0; i < this->GetNumberOfRepresentations(); ++i) |
| 43 | { |
| 44 | vtkDataRepresentation* rep = this->GetRepresentation(i); |
| 45 | graphRep = vtkRenderedGraphRepresentation::SafeDownCast(rep); |
| 46 | if (graphRep) |
| 47 | { |
| 48 | break; |
| 49 | } |
| 50 | } |
| 51 | if (!graphRep) |
| 52 | { |
| 53 | vtkSmartPointer<vtkDirectedGraph> g = vtkSmartPointer<vtkDirectedGraph>::New(); |
| 54 | graphRep = vtkRenderedGraphRepresentation::SafeDownCast(this->AddRepresentationFromInput(g)); |
| 55 | } |
| 56 | return graphRep; |
| 57 | } |
| 58 | |
| 59 | //------------------------------------------------------------------------------ |
| 60 | vtkDataRepresentation* vtkGraphLayoutView::CreateDefaultRepresentation(vtkAlgorithmOutput* port) |
no test coverage detected