if(!bbGetInputOrigin().empty() && bbGetInputTransform() != NULL)
{
//image = vtkImageChangeInformation::New();
+//EED 2017-01-01 Migration VTK7
+#if VTK_MAJOR_VERSION <= 5
image->SetInput( bbGetInputIn() );
+#else
+ image->SetInputData( bbGetInputIn() );
+#endif
image->SetOutputSpacing( 1,1,1 );
if(bbGetInputCentered())
{
image->CenterImageOn();
}
-
- double tmpbackInfo[19];
+ image->Update();
+ double tmpbackInfo[19];
GetBackInfo(tmpbackInfo,bbGetInputTransform()->GetMatrix(),bbGetInputOrigin() );
if ( CompareBackInfo(backInfoA,tmpbackInfo)==false )
GetBackInfo(backInfoA,bbGetInputTransform()->GetMatrix(),bbGetInputOrigin() );
//slicer =vtkImageReslice::New();
+//EED 2017-01-01 Migration VTK7
+#if VTK_MAJOR_VERSION <= 5
slicer->SetInput( image->GetOutput() );
+#else
+ slicer->SetInputData( image->GetOutput() );
+#endif
slicer->SetInformationInput( image->GetOutput() );
slicer->SetResliceTransform(bbGetInputTransform());
slicer->SetOutputOrigin( -(bbGetInputOrigin()[0]) , -(bbGetInputOrigin()[1]) , -(bbGetInputOrigin()[2]) );
slicer->Update();
//imageResult = vtkImageChangeInformation::New();
+//EED 2017-01-01 Migration VTK7
+#if VTK_MAJOR_VERSION <= 5
imageResult->SetInput( slicer->GetOutput() );
+#else
+ imageResult->SetInputData( slicer->GetOutput() );
+#endif
double spc[3];
bbGetInputIn()->GetSpacing(spc);
imageResult->SetOutputSpacing( spc );
imageResult->SetOutputOrigin( 0,0,0 );
-
+ imageResult->Update();
bbSetOutputOut( imageResult->GetOutput() );
if (bbGetInputTransform()!=NULL)
// Here does nothing
// but this is where you should allocate the internal/output pointers
// if any
- image = vtkImageChangeInformation::New();
- slicer =vtkImageReslice::New();
+ image = vtkImageChangeInformation::New();
+ slicer = vtkImageReslice::New();
imageResult = vtkImageChangeInformation::New();
}
void ReSlicerBox::bbUserFinalizeProcessing()
{
- image->Delete();
- slicer->Delete();
- imageResult->Delete();
+ image -> Delete();
+ slicer -> Delete();
+ imageResult -> Delete();
}
}