From 21066a51b61c0b0abfb0297a54a296a24c56ecca Mon Sep 17 00:00:00 2001 From: Simon Rit Date: Wed, 30 Jan 2013 11:08:59 +0100 Subject: [PATCH] Fix for bug 1882 --- vv/vvSlicer.cxx | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/vv/vvSlicer.cxx b/vv/vvSlicer.cxx index efaf80f..da0a5db 100644 --- a/vv/vvSlicer.cxx +++ b/vv/vvSlicer.cxx @@ -71,6 +71,7 @@ #include #if VTK_MAJOR_VERSION >= 6 || (VTK_MAJOR_VERSION >= 5 && VTK_MINOR_VERSION >= 10) # include +# include #endif vtkCxxRevisionMacro(vvSlicer, "DummyRevision"); @@ -958,7 +959,11 @@ void vvSlicer::UpdateDisplayExtent() // Image actor this->ImageActor->SetDisplayExtent(w_ext); - +#if VTK_MAJOR_VERSION >= 6 || (VTK_MAJOR_VERSION >= 5 && VTK_MINOR_VERSION >= 10) + // Fix for bug #1882 + dynamic_cast(this->ImageActor->GetMapper())->SetOrientation(this->GetOrientation()); +#endif + // Overlay image actor if (mOverlay && mOverlayActor->GetVisibility()) { AdjustResliceToSliceOrientation(mOverlayReslice); @@ -966,6 +971,10 @@ void vvSlicer::UpdateDisplayExtent() this->ConvertImageToImageDisplayExtent(input, w_ext, mOverlayReslice->GetOutput(), overExtent); ClipDisplayedExtent(overExtent, mOverlayMapper->GetInput()->GetWholeExtent()); mOverlayActor->SetDisplayExtent( overExtent ); +#if VTK_MAJOR_VERSION >= 6 || (VTK_MAJOR_VERSION >= 5 && VTK_MINOR_VERSION >= 10) + // Fix for bug #1882 + dynamic_cast(mOverlayActor->GetMapper())->SetOrientation(this->GetOrientation()); +#endif } // Fusion image actor @@ -975,6 +984,10 @@ void vvSlicer::UpdateDisplayExtent() this->ConvertImageToImageDisplayExtent(input, w_ext, mFusionReslice->GetOutput(), fusExtent); ClipDisplayedExtent(fusExtent, mFusionMapper->GetInput()->GetWholeExtent()); mFusionActor->SetDisplayExtent(fusExtent); +#if VTK_MAJOR_VERSION >= 6 || (VTK_MAJOR_VERSION >= 5 && VTK_MINOR_VERSION >= 10) + // Fix for bug #1882 + dynamic_cast(mFusionActor->GetMapper())->SetOrientation(this->GetOrientation()); +#endif } // Vector field actor -- 2.47.1