- cursor_lines->InsertNextCell( 2 );
- cursor_lines->InsertCellPoint( 4 );
- cursor_lines->InsertCellPoint( 5 );
- cursor_lines->InsertNextCell( 2 );
- cursor_lines->InsertCellPoint( 6 );
- cursor_lines->InsertCellPoint( 7 );
- this->Cursor->SetPoints( cursor_points );
- this->Cursor->SetLines( cursor_lines );
- this->CursorMapper->SetInputData( this->Cursor );
- this->CursorActor->SetMapper( this->CursorMapper );
+
+ this->m_Cursor = vtkSmartPointer< vtkPolyData >::New( );
+ this->m_CursorMapper = vtkSmartPointer< vtkPolyDataMapper >::New( );
+ this->m_CursorActor = vtkSmartPointer< vtkActor >::New( );
+
+ this->m_Cursor->SetPoints( cursor_points );
+ this->m_Cursor->SetLines( cursor_lines );
+ this->m_CursorMapper->SetInputData( this->m_Cursor );
+ this->m_CursorActor->SetMapper( this->m_CursorMapper );
+ this->m_CursorActor->GetProperty( )->SetColor( 1, 1, 0 );
+ this->m_CursorActor->GetProperty( )->SetLineWidth( 2 );
+
+ // Plane intersections
+ this->m_Axis1 = vtkSmartPointer< vtkPolyData >::New( );
+ this->m_Axis1Mapper = vtkSmartPointer< vtkPolyDataMapper >::New( );
+ this->m_Axis1Actor = vtkSmartPointer< vtkActor >::New( );
+
+ vtkSmartPointer< vtkPoints > h_points =
+ vtkSmartPointer< vtkPoints >::New( );
+ vtkSmartPointer< vtkCellArray > h_lines =
+ vtkSmartPointer< vtkCellArray >::New( );
+ h_points->InsertNextPoint( 0, 0, 0 );
+ h_points->InsertNextPoint( 0, 0, 0 );
+ h_lines->InsertNextCell( 2 );
+ h_lines->InsertCellPoint( 0 );
+ h_lines->InsertCellPoint( 1 );
+ this->m_Axis1->SetPoints( h_points );
+ this->m_Axis1->SetLines( h_lines );
+ this->m_Axis1Mapper->SetInputData( this->m_Axis1 );
+ this->m_Axis1Actor->SetMapper( this->m_Axis1Mapper );
+
+ this->m_Axis2 = vtkSmartPointer< vtkPolyData >::New( );
+ this->m_Axis2Mapper = vtkSmartPointer< vtkPolyDataMapper >::New( );
+ this->m_Axis2Actor = vtkSmartPointer< vtkActor >::New( );
+
+ vtkSmartPointer< vtkPoints > v_points =
+ vtkSmartPointer< vtkPoints >::New( );
+ vtkSmartPointer< vtkCellArray > v_lines =
+ vtkSmartPointer< vtkCellArray >::New( );
+ v_points->InsertNextPoint( 0, 0, 0 );
+ v_points->InsertNextPoint( 0, 0, 0 );
+ v_lines->InsertNextCell( 2 );
+ v_lines->InsertCellPoint( 0 );
+ v_lines->InsertCellPoint( 1 );
+ this->m_Axis2->SetPoints( v_points );
+ this->m_Axis2->SetLines( v_lines );
+ this->m_Axis2Mapper->SetInputData( this->m_Axis2 );
+ this->m_Axis2Actor->SetMapper( this->m_Axis2Mapper );
+
+ // Plane
+ this->m_Plane = vtkSmartPointer< vtkPolyData >::New( );
+ this->m_PlaneMapper = vtkSmartPointer< vtkPolyDataMapper >::New( );
+ this->m_PlaneActor = vtkSmartPointer< vtkActor >::New( );