]> Creatis software - clitk.git/blobdiff - itk/clitkSegmentationUtils.txx
Moved from repository clitk to clitk.private/tests_dav
[clitk.git] / itk / clitkSegmentationUtils.txx
index 76572b594540e9f7393e38a535a40ff3f4ffcb52..6171030d9109807f0c2d2a9cf80782087c7c8279 100644 (file)
@@ -766,8 +766,7 @@ namespace clitk {
   {
     assert((mainDirection==0) || (mainDirection==1));
     typedef itk::ImageSliceIteratorWithIndex<ImageType> SliceIteratorType;
-    SliceIteratorType siter = SliceIteratorType(input, 
-                                                input->GetLargestPossibleRegion());
+    SliceIteratorType siter = SliceIteratorType(input, input->GetLargestPossibleRegion());
     siter.SetFirstDirection(0);
     siter.SetSecondDirection(1);
     siter.GoToBegin();
@@ -786,7 +785,6 @@ namespace clitk {
         A = lA[i];
         B = lB[i];
         C = A;
-      
         // Check that the line is not a point (A=B)
         bool p = (A[0] == B[0]) && (A[1] == B[1]);
       
@@ -1373,6 +1371,7 @@ namespace clitk {
     iter2.GoToBegin();
     double dmin = 100000.0;
     typename ImageType::IndexType indexmin;
+    indexmin.Fill(0);
     while (!iter1.IsAtEnd()) {
       if (iter1.Get() != BG) {
         double d = iter2.Get();