From: dsarrut Date: Thu, 24 Mar 2011 15:46:41 +0000 (+0000) Subject: Correct VFResample (now should work) X-Git-Tag: v1.2.0~124 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=65aef3ac46440b21894dd0b360acaaabb906bea8;p=clitk.git Correct VFResample (now should work) --- diff --git a/tools/clitkVFResampleGenericFilter.cxx b/tools/clitkVFResampleGenericFilter.cxx index 2cd6b7d..6bbcff5 100755 --- a/tools/clitkVFResampleGenericFilter.cxx +++ b/tools/clitkVFResampleGenericFilter.cxx @@ -17,15 +17,6 @@ ======================================================================-====*/ #ifndef CLITKVFRESAMPLEGENERICFILTER_CXX #define CLITKVFRESAMPLEGENERICFILTER_CXX -/** - ------------------------------------------------------------------- - * @file clitkVFResampleGenericFilter.cxx - * @author David Sarrut - * @date 23 Feb 2008 08:37:53 - - * @brief - - -------------------------------------------------------------------*/ #include "clitkVFResampleGenericFilter.h" @@ -35,7 +26,7 @@ clitk::VFResampleGenericFilter::VFResampleGenericFilter(): { InitializeImageType<2>(); InitializeImageType<3>(); - InitializeImageType<4>(); + // InitializeImageType<4>(); mApplyGaussianFilterBefore = false; mDefaultPixelValue = 0.0; mInterpolatorName = "NN"; @@ -48,7 +39,9 @@ clitk::VFResampleGenericFilter::VFResampleGenericFilter(): template void clitk::VFResampleGenericFilter::InitializeImageType() { - ADD_IMAGE_TYPE(Dim, float); + //typedef itk::Vector v3f; + //ADD_IMAGE_TYPE(Dim, v3f); + ADD_VEC_IMAGE_TYPE(Dim, Dim, float) } //-------------------------------------------------------------------- @@ -75,7 +68,8 @@ template void clitk::VFResampleGenericFilter::Update_WithDimAndPixelTypeAndComponent() { // Reading input - typedef itk::Vector DisplacementType; + // typedef itk::Vector DisplacementType; + typedef PixelType DisplacementType; typedef itk::Image< DisplacementType, Dim > ImageType; typename ImageType::Pointer input = clitk::readImage(m_InputFilenames, m_IOVerbose); diff --git a/tools/clitkVFResampleGenericFilter.h b/tools/clitkVFResampleGenericFilter.h index 351a6fc..b98d200 100755 --- a/tools/clitkVFResampleGenericFilter.h +++ b/tools/clitkVFResampleGenericFilter.h @@ -100,8 +100,6 @@ namespace clitk { }; // end class VFResampleGenericFilter //-------------------------------------------------------------------- -#include "clitkVFResampleGenericFilter.txx" - } // end namespace //--------------------------------------------------------------------