X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=itk%2FitkBSplineInterpolateImageFunctionWithLUT.txx;h=b9354a5e13ce2d13762de9a7f5eefef4f7d410e8;hb=fc2b78aedceae6ebeb0dbe8aae649bc84fd8e235;hp=35c1664f6ef82e37fcd7963a8844be75e9df5631;hpb=6512df02372cfb3507bf1799115511a68ab5036e;p=clitk.git diff --git a/itk/itkBSplineInterpolateImageFunctionWithLUT.txx b/itk/itkBSplineInterpolateImageFunctionWithLUT.txx index 35c1664..b9354a5 100644 --- a/itk/itkBSplineInterpolateImageFunctionWithLUT.txx +++ b/itk/itkBSplineInterpolateImageFunctionWithLUT.txx @@ -3,7 +3,7 @@ Authors belong to: - University of LYON http://www.universite-lyon.fr/ - - Léon Bérard cancer center http://oncora1.lyon.fnclcc.fr + - Léon Bérard cancer center http://www.centreleonberard.fr - CREATIS CNRS laboratory http://www.creatis.insa-lyon.fr This software is distributed WITHOUT ANY WARRANTY; without even @@ -14,9 +14,10 @@ - BSD See included LICENSE.txt file - CeCILL-B http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html -======================================================================-====*/ +===========================================================================**/ #ifndef _ITKINTERPOLATEIMAGEFUNCTIONWITHLUT_TXX #define _ITKINTERPOLATEIMAGEFUNCTIONWITHLUT_TXX +#include namespace itk { @@ -190,7 +191,7 @@ namespace itk // Compute index in precomputed weights table TCoefficientType t2 = mSamplingFactors[l]*t1; - index[l] = (IndexValueType)Math::Round(t2); + index[l] = (IndexValueType)Math::Round(t2); // For even order : test if too close to 0.5 (but lower). In this // case : take the next coefficient @@ -240,7 +241,7 @@ namespace itk evaluateIndex[l] = indx; } else { // Use this index calculation for even splineOrder - if (mSplineOrders[l] == 0) evaluateIndex[l] = Math::Round(x[l]); + if (mSplineOrders[l] == 0) evaluateIndex[l] = Math::Round(x[l]); else { indx = (long)vcl_floor((x[l]+ 0.5)) - mSplineOrders[l] / 2; //this->m_SplineOrder / 2; evaluateIndex[l] = indx;