X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=vv%2FvvSlicer.cxx;h=2089d41caa3d564e5e076b0e3f94df4710d56fb5;hb=HEAD;hp=7405a450bb67f3e35f23aedfbd39abba34cfa8cf;hpb=f4eb79e1b67e9c592a1deba19aa94af365bf2df9;p=clitk.git diff --git a/vv/vvSlicer.cxx b/vv/vvSlicer.cxx index 7405a45..2089d41 100644 --- a/vv/vvSlicer.cxx +++ b/vv/vvSlicer.cxx @@ -24,6 +24,7 @@ #include "vvSlicerManagerCommand.h" #include "vvGlyphSource.h" #include "vvGlyph2D.h" +#include "vvUtils.h" #include #include @@ -134,7 +135,7 @@ vvSlicer::vvSlicer() pdmA = vtkSmartPointer::New(); pdmA->SetMapper(pdm); - pdmA->GetProperty()->SetColor(255,10,212); + pdmA->GetProperty()->SetColor(1,0,0); pdmA->SetVisibility(0); pdmA->SetPickable(0); @@ -268,7 +269,7 @@ void vvSlicer::ToggleContourSuperposition() //------------------------------------------------------------------------------ -void vvSlicer::SetCursorColor(int r,int g, int b) +void vvSlicer::SetCursorColor(double r, double g, double b) { pdmA->GetProperty()->SetColor(r,g,b); } @@ -352,6 +353,8 @@ void vvSlicer::SetImage(vvImage::Pointer image) if (!mImageReslice) { mImageReslice = vtkSmartPointer::New(); mImageReslice->SetInterpolationModeToLinear(); + SetInterpolationImageReslice(getInterpolationFavoriteStatus()); + GetImageActor()->SetInterpolate(getInterpolationFavoriteStatus()); mImageReslice->AutoCropOutputOn(); mImageReslice->SetBackgroundColor(-1000,-1000,-1000,1); } @@ -455,6 +458,7 @@ void vvSlicer::SetOverlay(vvImage::Pointer overlay) #if VTK_MAJOR_VERSION >= 6 || (VTK_MAJOR_VERSION >= 5 && VTK_MINOR_VERSION >= 10) mOverlayActor->GetMapper()->BorderOn(); #endif + mOverlayActor->SetInterpolate(getInterpolationFavoriteStatus()); } //stupid but necessary : the Overlay need to be rendered before fusion @@ -530,6 +534,7 @@ void vvSlicer::SetFusion(vvImage::Pointer fusion, int fusionSequenceCode) mFusionActor->GetMapper()->BorderOn(); #endif + mFusionActor->SetInterpolate(getInterpolationFavoriteStatus()); this->GetRenderer()->AddActor(mFusionActor); } @@ -983,7 +988,7 @@ void vvSlicer::SetSliceOrientation(int orientation) copyExtent(ext, extent); #endif - if (extent[5]-extent[4] <= 2) + if (extent[5]-extent[4] < 1) orientation = vtkImageViewer2::SLICE_ORIENTATION_XY; if (orientation < vtkImageViewer2::SLICE_ORIENTATION_YZ ||