X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FmaracasVisuLib%2Fsrc%2Finterface%2FwxWindows%2Fwidgets%2FwxVtkClipping3DView.cxx;h=b41609ebcb2fb5cc3928edadecd3cf5ef7ab158a;hb=ca35b13e046343c8b50cbd6b833828b06c9d1608;hp=84c3c609dd20fdad9e612e648d49aed7ff9dd065;hpb=97dee12beaba08089198ed7bab9544b8b4c4f240;p=creaMaracasVisu.git diff --git a/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkClipping3DView.cxx b/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkClipping3DView.cxx index 84c3c60..b41609e 100644 --- a/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkClipping3DView.cxx +++ b/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxVtkClipping3DView.cxx @@ -168,19 +168,21 @@ void wxVtkClipping3DView::Configure() _wxvtk3Dbaseview->Configure(); // Actors are added to the renderer. - _wxvtk3Dbaseview->GetRenderer()->AddActor( _vtkclipping3Ddataviewer->GetOutlineActor() ); _boxWidgetS1 = vtkBoxWidget::New(); _boxWidgetS1->SetInteractor( _wxvtk3Dbaseview->GetWxVTKRenderWindowInteractor() ); _boxWidgetS1->SetPlaceFactor(1.25); - - vtkStripper *stripper=_vtkclipping3Ddataviewer->GetTissueStripper(0); vtkPolyData *polydata= stripper->GetOutput(); - +//EED 2017-01-01 Migration VTK7 +#if VTK_MAJOR_VERSION <= 5 _boxWidgetS1->SetInput( polydata ); +#else + stripper->Update(); + _boxWidgetS1->SetInputData( polydata ); +#endif //EED 2016-08-19 //_boxWidgetS1->PlaceWidget(); @@ -218,7 +220,14 @@ void wxVtkClipping3DView::Configure() _boxWidgetVolume = vtkBoxWidget::New(); _boxWidgetVolume->SetInteractor( _wxvtk3Dbaseview->GetWxVTKRenderWindowInteractor() ); _boxWidgetVolume->SetPlaceFactor(1.25); + +//EED 2017-01-01 Migration VTK7 +#if VTK_MAJOR_VERSION <= 5 _boxWidgetVolume->SetInput( this->GetVtkClipping3DDataViewer()->GetVtkMPRBaseData()->GetImageData() ); +#else + _boxWidgetVolume->SetInputData( this->GetVtkClipping3DDataViewer()->GetVtkMPRBaseData()->GetImageData() ); +#endif + _boxWidgetVolume->PlaceWidget(); _boxWidgetVolume->AddObserver( vtkCommand::InteractionEvent, _vtkclipping3Ddataviewer->GetObserverV() ); _boxWidgetVolume->HandlesOn (); @@ -255,6 +264,7 @@ void wxVtkClipping3DView::Configure() _vtkclipping3Ddataviewer->SetRenderer(this->GetWxvtk3Dbaseview()->GetRenderer()); _vtkclipping3Ddataviewer->SetInteractor(this->GetWxvtk3Dbaseview()->GetWxVTKRenderWindowInteractor()); } + //------------------------------------------------------------------- void wxVtkClipping3DView::SetVtkClipping3DDataViewer(vtkClipping3DDataViewer *vtkclipping3Ddataviewer) {