From: Simon Rit Date: Wed, 30 Jan 2013 10:08:59 +0000 (+0100) Subject: Fix for bug 1882 X-Git-Tag: v1.4.0~249^2~5 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;ds=sidebyside;h=21066a51b61c0b0abfb0297a54a296a24c56ecca;hp=e2d2096e1a3a4afdad6446bf09d0e05f47d9b7eb;p=clitk.git Fix for bug 1882 --- 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