X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FmaracasVisuLib%2Fsrc%2Finterface%2FwxWindows%2Fwidgets%2FwxSphereView.cxx;h=180e4cd182ed1326275d88a833816412853adf23;hb=255f774ce4100c0b84e6b5efa5c64d0db77f8a61;hp=961918187031c5118bb9d2c959e8aa8d29bc9b43;hpb=b80b4dcc301c1c2c63c0f76cd06b0a434350f7a7;p=creaMaracasVisu.git diff --git a/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxSphereView.cxx b/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxSphereView.cxx index 9619181..180e4cd 100644 --- a/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxSphereView.cxx +++ b/lib/maracasVisuLib/src/interface/wxWindows/widgets/wxSphereView.cxx @@ -38,12 +38,18 @@ wxSphereView::wxSphereView( wxWindow *parent, vtkMPRBaseData *vtkmprbasedata/*, _imageSphere = vtkImageData::New(); _imageSphere->SetDimensions (150,150,500); +//EED 2017-01-01 Migration VTK7 +#if VTK_MAJOR_VERSION <= 5 //EED // _imageSphere->SetScalarTypeToUnsignedShort(); _imageSphere->SetScalarType( _imageDataOriginal->GetScalarType() ); - _imageSphere->AllocateScalars(); _imageSphere->Update(); +#else + _imageSphere->AllocateScalars(_imageDataOriginal->GetScalarType(),1); +#endif + + //EED ???? vtkBaseData no esta compartido con los otros objetos .. PLOP // vtkBaseData *vtkbasedata = new vtkBaseData(); @@ -158,7 +164,12 @@ void wxSphereView::Refresh( ) void wxSphereView::RefreshView() { //EED - _imageViewer2XYZ->GetVtkImageViewer2()->SetInput ( _imageSphere ); +//EED 2017-01-01 Migration VTK7 +#if VTK_MAJOR_VERSION <= 5 + _imageViewer2XYZ->GetVtkImageViewer2()->SetInput( _imageSphere ); +#else + _imageViewer2XYZ->GetVtkImageViewer2()->SetInputData( _imageSphere ); +#endif DefineImageSphere(); // UpdateColorWindowLevel(); // wxVtk2DBaseView::Refresh(); @@ -419,7 +430,12 @@ void wxSphereView::FiltreImageB(int id, double radio, bool ok,int deltaTMP) } } _imageSphere->Modified(); +//EED 2017-01-01 Migration VTK7 +#if VTK_MAJOR_VERSION <= 5 _imageSphere->Update(); +#else + // .. +#endif } //----------------------------------------------------------------------------