]> Creatis software - clitk.git/blobdiff - itk/clitkInvertVFFilter.txx
Remove tmp files
[clitk.git] / itk / clitkInvertVFFilter.txx
index 3df8aca45b7fa55508389cf04a0ceb05a648aba0..0c443ca8e4812764371fda4520cb3f0cbe73b021 100644 (file)
@@ -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,7 +14,7 @@
 
   - BSD        See included LICENSE.txt file
   - CeCILL-B   http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html
-======================================================================-====*/
+===========================================================================**/
 #ifndef __clitkInvertVFFilter_txx
 #define __clitkInvertVFFilter_txx
 namespace
@@ -119,7 +119,7 @@ void HelperClass1<InputImageType, OutputImageType>::ThreadedGenerateData(const O
 
   //Get pointer to the output
   typename OutputImageType::Pointer outputPtr = this->GetOutput();
-  typename OutputImageType::SizeType size=outputPtr->GetLargestPossibleRegion().GetSize();
+  //typename OutputImageType::SizeType size=outputPtr->GetLargestPossibleRegion().GetSize();
 
   //Iterator over input
   typedef itk::ImageRegionConstIteratorWithIndex<InputImageType> InputImageIteratorType;
@@ -178,7 +178,7 @@ void HelperClass1<InputImageType, OutputImageType>::ThreadedGenerateData(const O
         upper = counter;  // each bit indicates upper/lower neighbour
 
         // get neighbor index and overlap fraction
-        for( dim = 0; dim < 3; dim++ ) {
+        for( dim = 0; dim < ImageDimension; dim++ ) {
           if ( upper & 1 ) {
             neighIndex[dim] = baseIndex[dim] + 1;
             overlap *= distance[dim];
@@ -398,7 +398,6 @@ template <class InputImageType, class OutputImageType> void InvertVFFilter<Input
   typename OutputImageType::IndexType start;
   for (unsigned int i=0; i< ImageDimension; i++) start[i]=0;
   region.SetIndex(start);
-  PixelType zero = itk::NumericTraits<double>::Zero;
 
 
   //Allocate the weights