]> Creatis software - bbtk.git/commitdiff
2344 BBTK Bug New Normal Conflict between Update and Modfied vtk filters
authorEduardo DAVILA <eduardo.davila@creatis.insa-lyon.fr>
Fri, 21 Mar 2014 14:28:20 +0000 (15:28 +0100)
committerEduardo DAVILA <eduardo.davila@creatis.insa-lyon.fr>
Fri, 21 Mar 2014 14:28:20 +0000 (15:28 +0100)
packages/vtk/src/bbvtkBinaryOperations.cxx
packages/vtk/src/bbvtkExtractVtkImageFilter.cxx
packages/vtk/src/bbvtkImageCastToUShort.cxx
packages/vtk/src/bbvtkImageContinuousDilate3D.xml
packages/vtk/src/bbvtkImageContinuousErode3D.xml
packages/vtk/src/bbvtkImageDilateErode3D.xml
packages/vtk/src/bbvtkImageGaussianSmooth.xml
packages/vtk/src/bbvtkSegmentationConnectivity.cxx
packages/vtk/src/bbvtkUnaryOperations.cxx
packages/vtk/src/bbvtkVecImageGaussianSmooth.cxx

index 4689f75c0800e441308ac1510a341e3c1a98f880..774cd19140321341105b56bc4b0751b009e563ab 100644 (file)
@@ -90,6 +90,7 @@ void BinaryOperations::Process()
                break;
        }
 
+       ope->Modified();
        ope->Update();
        vtkImageData* salida = ope->GetOutput();
 
index 50f8618e48ad20c9f3fad645891478626303d94e..efbbe227e7eb91a17ed86c540eda84e5d8d409dc 100644 (file)
@@ -52,6 +52,7 @@ void ExtractVtkImageFilter::Process()
        _extract->SetInput( bbGetInputIn() );
        _extract->SetVOI(voi);  
        _extract->UpdateWholeExtent();
+       _extract->Modified();
        _extract->Update();
        bbSetOutputOut(_extract->GetOutput());
 }
index 8e60e7ef2bca13cce733d43157974dc789d0d72d..6543e0620e721bbb2e5a3ada7b9177460b4d4b04 100644 (file)
@@ -50,6 +50,7 @@ void ImageCastToUShort::Process()
        vtkImageData* img = bbGetInputIn();     
        cast->SetInput(img);
        cast->SetOutputScalarTypeToUnsignedShort();
+       cast->Modified();
        cast->Update();
     bbSetOutputOut(cast->GetOutput() );   
 }
index a07648630721bd422041b18c698929d3e5870dca..31a11c37a8a851fa390f9923f7faa9ab61d1084b 100644 (file)
@@ -22,6 +22,7 @@
 bbGetVtkObject()->SetKernelSize(bbGetInputKernelSizeX(), 
               bbGetInputKernelSizeY(), 
               bbGetInputKernelSizeZ());
+bbGetVtkObject()->Modified();
 bbGetVtkObject()->Update();
 </PRE>
 </process>
index 07a98d066a5cfe264b6965089c4ec157fd89448b..f1326061150b288492a41d43ec3e2e4abed28676 100644 (file)
@@ -22,6 +22,7 @@
 bbGetVtkObject()->SetKernelSize(bbGetInputKernelSizeX(), 
               bbGetInputKernelSizeY(), 
               bbGetInputKernelSizeZ());
+bbGetVtkObject()->Modified();
 bbGetVtkObject()->Update();
 </PRE>
 </process>
index 352d4366adaff4c066e9ef4dc4df45fc212dba0d..2f7c2e20c7b0f44073681f816d5d486806787ff2 100644 (file)
@@ -24,6 +24,7 @@
 bbGetVtkObject()->SetKernelSize(bbGetInputKernelSizeX(), 
               bbGetInputKernelSizeY(), 
               bbGetInputKernelSizeZ());
+bbGetVtkObject()->Modified();
 bbGetVtkObject()->Update();
 </PRE>
 </process>
index b7450d2a12bb5a92fac8572651377bfab99d59d1..3c3dd79ca4e9859a7bcfc44568fcb7785c66c8c7 100644 (file)
 
 <process>
 <PRE>
-    printf("EED ImageGaussianSmooth::Process start \n");
+    printf("EED ImageGaussianSmooth::Process start a\n");
     bbGetVtkObject()->SetStandardDeviation(bbGetInputStdDevX(), 
                                        bbGetInputStdDevY(), 
                                        bbGetInputStdDevZ());
+    bbGetVtkObject()->Modified();
     bbGetVtkObject()->Update();
     printf("EED ImageGaussianSmooth::Process end \n");
 </PRE>
index 6ec480d58c641086a2ad5a9f1c0ecfe2cc9f8c8a..679e0706aa5530eb68a30d28860d995f98e7ac86 100644 (file)
@@ -129,7 +129,9 @@ namespace bbvtk
     thresh2->ThresholdBetween(3000, 3001);
     thresh2->SetInput(imagedata);
     thresh2->ThresholdBetween(bbGetInputThresholdMinMax()[0], bbGetInputThresholdMinMax()[1]);
+    thresh2->Modified();
     thresh2->Update();
+    cast2->Modified();
     cast2->Update();
     connect2->RemoveAllSeeds ();
          
@@ -151,6 +153,7 @@ namespace bbvtk
          if ( z>=maxz ) {  printf("Warnnig bbtk::vtk::SegmentationConnectivity::DoProcess limites of the image out of range z: %d -> %d \n",y, maxz-1 ); z=maxz-1; }
          
          connect2->AddSeed( x,y,z );
+         connect2->Modified();
          connect2->Update();
          cast4->Update();                      
          bbSetOutputOut(cast4->GetOutput() );
index d6e9601c05da59b1e3be59d05038b014489bb002..dfc3cc9a894a56d0a9328ed7a3ca1503ee1c1fab 100644 (file)
@@ -124,6 +124,7 @@ printf("EED UnaryOperations::Process()  3 \n");
                break;
        }
 
+       ope->Modified();
        ope->Update();
        vtkImageData* salida = ope->GetOutput();
 
index a2ccc9a5f9a1eeb8425a5fbffcad9d84881c460d..33af404643cc8de4484d5722c58b5136f4856e9e 100644 (file)
@@ -84,6 +84,7 @@ BBTK_BLACK_BOX_IMPLEMENTATION(VecImageGaussianSmooth,bbtk::AtomicBlackBox);
                        vtkimagegaussiansmooth = vtkImageGaussianSmooth::New();
                        vtkimagegaussiansmooth->SetInput( bbGetInputIn()[i] );
                        vtkimagegaussiansmooth->SetStandardDeviation( stdvX,stdvY, stdvZ ); 
+                       vtkimagegaussiansmooth->Modified();
                        vtkimagegaussiansmooth->Update();
                        VecResult.push_back( vtkimagegaussiansmooth->GetOutput() );
                        VecVtkimagegaussiansmooth.push_back(vtkimagegaussiansmooth);