1 #include <cpPlugins/Interface/Mesh.h>
3 #include <vtkPolyData.h>
5 // -------------------------------------------------------------------------
6 void cpPlugins::Interface::Mesh::
7 SetVTKMesh( vtkPolyData* mesh )
9 this->m_VTKObject = mesh;
11 this->m_Mapper = vtkSmartPointer< vtkPolyDataMapper >::New( );
12 this->m_Actor = vtkSmartPointer< vtkActor >::New( );
14 this->m_Mapper->SetInputData( mesh );
15 this->m_Actor->SetMapper( this->m_Mapper );
20 // -------------------------------------------------------------------------
21 vtkPolyData* cpPlugins::Interface::Mesh::
24 return( dynamic_cast< vtkPolyData* >( this->m_VTKObject.GetPointer( ) ) );
27 // -------------------------------------------------------------------------
28 const vtkPolyData* cpPlugins::Interface::Mesh::
32 dynamic_cast< const vtkPolyData* >( this->m_VTKObject.GetPointer( ) )
36 // -------------------------------------------------------------------------
37 vtkActor* cpPlugins::Interface::Mesh::
40 return( this->m_Actor );
43 // -------------------------------------------------------------------------
44 const vtkActor* cpPlugins::Interface::Mesh::
47 return( this->m_Actor );
50 // -------------------------------------------------------------------------
51 cpPlugins::Interface::Mesh::
55 this->m_ClassName = "cpPlugins::Interface::Mesh";
56 this->m_ClassCategory = "BasicObject";
59 // -------------------------------------------------------------------------
60 cpPlugins::Interface::Mesh::