]> Creatis software - bbtk.git/commitdiff
Clean code
authorEduardo DAVILA <davila@creatis.insa-lyon.fr>
Mon, 2 Jan 2023 16:25:22 +0000 (17:25 +0100)
committerEduardo DAVILA <davila@creatis.insa-lyon.fr>
Mon, 2 Jan 2023 16:25:22 +0000 (17:25 +0100)
packages/vtk/src/bbvtkImageGaussianSmooth.xml
packages/vtk/src/bbvtkMarchingCubes.cxx
packages/vtk/src/bbvtkMarchingCubes.h

index 9daabbde327bcbabe772d23bd5b4d9e8c7798690..780c20ad01ecdd77079f1700f2b3897e71baad14 100644 (file)
 
 <process>
 <PRE>
-    bbGetVtkObject()->SetStandardDeviation(bbGetInputStdDevX(), 
+    bbGetVtkObject()->SetStandardDeviation(bbGetInputStdDevX(),
                                        bbGetInputStdDevY(), 
                                        bbGetInputStdDevZ());
     bbGetVtkObject()->Modified();
     bbGetVtkObject()->Update();
+    if (bbGetInputIn()==NULL)
+    {
+        printf("EED ImageGaussianSmooth  This mechanism is not working, try to use box ImageGaussianSmooth2.\n");
+        bbSetOutputOut(NULL);
+    } else {
+        bbSetOutputOut( bbGetVtkObject()->GetOutput() );
+    }
 </PRE>
 
 </process>
index 48272acf764dd8cfa5cef7ea58eccd3cbad39f28..c82ca61b7d19ca42edbf29bcc7ff15889080ba6e 100644 (file)
@@ -56,21 +56,18 @@ namespace bbvtk
             if (bbGetInputActive()==true)
             {
                 bbGetVtkObject()->SetValue(0, bbGetInputValue() );
-                
                 if(bbGetInputComputeNormalsOn())
                 {
                     bbGetVtkObject()->ComputeNormalsOn();
                 }else {
                     bbGetVtkObject()->ComputeNormalsOff();
                 }// if Normals
-                
                 if(bbGetInputComputeScalarsOn())
                 {
                     bbGetVtkObject()->ComputeScalarsOn();
                 }else{
                     bbGetVtkObject()->ComputeScalarsOff();
                 }// if Scalars
-                
                 bbGetVtkObject()->Update();
             } // Active
        }
@@ -97,10 +94,7 @@ namespace bbvtk
                BBTK_VTK_FINALIZE_PROCESSING();
        }       
        
-       
 } // EO namespace bbvtk
-
-
 #endif //_USE_VTK_
 
 
index 4c235f9aa1c8cef448dc440d2346838e9c13403b..011834a126f547205c117424ecce0100db6b77a6 100644 (file)
@@ -116,7 +116,7 @@ namespace bbvtk
 
   BBTK_INPUT(MarchingCubes,Active,"Active true/false (default true)",bool,"");
   BBTK_INPUT(MarchingCubes,In,"Image",vtkImageData*,"");
-  BBTK_INPUT(MarchingCubes,Value,"Value of the iso-surface",double,"");
+  BBTK_INPUT(MarchingCubes,Value,"(default 400) Value of the iso-surface",double,"");
   BBTK_INPUT(MarchingCubes,ComputeNormalsOn,"Set the computation of normals",bool,"");
   BBTK_INPUT(MarchingCubes,ComputeScalarsOn,"Set the computation of scalars",bool,"");
   BBTK_OUTPUT(MarchingCubes,Out,"Output iso-surface",vtkPolyData*,"");