+ // EED MPR view orientation correction..
+ vtkImageFlip *flipYFilter = vtkImageFlip::New();
+ flipYFilter->SetFilteredAxis(1); // flip y axis
+
+//EED 2017-01-01 Migration VTK7
+#if (VTK_MAJOR_VERSION <= 5)
+ flipYFilter->SetInput( planeWidgetX->GetResliceOutput() );
+#endif
+#if (VTK_MAJOR_VERSION >= 6)
+ flipYFilter->SetInputData( planeWidgetX->GetResliceOutput() );
+#endif
+
+ flipYFilter->Update();
+
+ vtkImageChangeInformation *image = vtkImageChangeInformation::New();
+
+//EED 2017-01-01 Migration VTK7
+#if (VTK_MAJOR_VERSION <= 5)
+ image->SetInput( planeWidgetY->GetResliceOutput() );
+#endif
+#if (VTK_MAJOR_VERSION >= 6)
+ image->SetInputData( planeWidgetY->GetResliceOutput() );
+#endif
+
+ image->SetOutputSpacing( 1,1,1 );
+ image->CenterImageOn();
+ image->Update();
+ _imageTransform = vtkTransform::New();
+ vtkImageReslice *slicer =vtkImageReslice::New();
+
+//EED 2017-01-01 Migration VTK7
+#if (VTK_MAJOR_VERSION <= 5)
+ slicer->SetInput( image->GetOutput() );
+#endif
+#if (VTK_MAJOR_VERSION >= 6)
+ slicer->SetInputData( image->GetOutput() );
+#endif
+
+ slicer->SetInformationInput( image->GetOutput() );
+ slicer->SetResliceTransform( _imageTransform );
+ slicer->SetOutputOrigin(0 , 0 , 0 );
+ slicer->SetInterpolationModeToNearestNeighbor();
+ slicer->Update();
+ vtkImageChangeInformation *imageResult = vtkImageChangeInformation::New();
+
+//EED 2017-01-01 Migration VTK7
+#if (VTK_MAJOR_VERSION <= 5)
+ imageResult->SetInput( slicer->GetOutput() );
+#endif
+#if (VTK_MAJOR_VERSION >= 6)
+ imageResult->SetInputData( slicer->GetOutput() );
+#endif
+
+ double spc[3];
+ planeWidgetY->GetResliceOutput()->GetSpacing(spc);
+ imageResult->SetOutputSpacing( spc[1], spc[0], spc[2] );
+ imageResult->SetOutputOrigin( 0,0,0 );
+
+