From: tbaudier Date: Tue, 26 Sep 2017 09:26:02 +0000 (+0200) Subject: Reslice with correct spacing X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=92044073d6c8ff23ca0ebb8664e46c0a8cf86ea0;p=clitk.git Reslice with correct spacing --- diff --git a/vv/vvSlicer.cxx b/vv/vvSlicer.cxx index 10396a6..bcfbbfc 100644 --- a/vv/vvSlicer.cxx +++ b/vv/vvSlicer.cxx @@ -359,8 +359,7 @@ void vvSlicer::SetImage(vvImage::Pointer image) mConcatenatedTransform->Identity(); mConcatenatedTransform->Concatenate(mImage->GetTransform()[0]); mConcatenatedTransform->Concatenate(mSlicingTransform); - mImageReslice->SetResliceTransform(mConcatenatedTransform); - //mImageReslice->SetResliceAxes(mConcatenatedTransform->GetMatrix()); + mImageReslice->SetResliceAxes(mConcatenatedTransform->GetMatrix()); #if VTK_MAJOR_VERSION <= 5 mImageReslice->SetInput(0, mImage->GetFirstVTKImageData()); #else @@ -378,8 +377,7 @@ void vvSlicer::SetImage(vvImage::Pointer image) #if VTK_MAJOR_VERSION <= 5 this->GetInput()->GetWholeExtent(extent); #else - int* ext = mImageReslice->GetInputInformation()->Get(vtkStreamingDemandDrivenPipeline::WHOLE_EXTENT()); - copyExtent(ext, extent); + mImageReslice->GetOutput()->GetExtent(extent); #endif // Prevent crash when reload -> change slice if outside extent