]> Creatis software - creaCLI.git/blobdiff - bbtk_Slicer_PKG/src/bbSlicerGrayscaleFillHole.h
All Slicer modules succesfully compiled into BBTK boxes :P
[creaCLI.git] / bbtk_Slicer_PKG / src / bbSlicerGrayscaleFillHole.h
diff --git a/bbtk_Slicer_PKG/src/bbSlicerGrayscaleFillHole.h b/bbtk_Slicer_PKG/src/bbSlicerGrayscaleFillHole.h
new file mode 100644 (file)
index 0000000..695d7e2
--- /dev/null
@@ -0,0 +1,60 @@
+#ifndef __bbSlicerGrayscaleFillHole_h_INCLUDED__
+#define __bbSlicerGrayscaleFillHole_h_INCLUDED__
+
+#include "bbSlicer_EXPORT.h"
+#include "bbtkAtomicBlackBox.h"
+
+#include <vector>
+#include <cstdlib>
+#include <dlfcn.h>
+#include <sstream>
+#include <fstream>
+#include <iostream>
+
+#include <ModuleDescriptionUtilities.h>
+#include <ModuleDescriptionParser.h>
+#include <ModuleParameterGroup.h>
+#include <ModuleDescription.h>
+#include <ModuleParameter.h>
+
+#include "CreationTool.h"
+
+namespace bbSlicer {
+
+    class bbSlicer_EXPORT GrayscaleFillHole
+    :
+    public bbtk::AtomicBlackBox {
+        BBTK_BLACK_BOX_INTERFACE ( GrayscaleFillHole , bbtk::AtomicBlackBox ) ;
+
+        // GENERATED ARGS        
+        
+BBTK_DECLARE_INPUT ( inputVolume , std::string );
+BBTK_DECLARE_INPUT ( outputVolume , std::string );
+
+        // EO GENERATED ARGS
+
+        BBTK_PROCESS ( Process ) ;
+        void Process ( ) ;
+    private:
+        void execute ( std::string lib , int _argc , char * _argv[] ) ;
+    } ;
+
+    BBTK_BEGIN_DESCRIBE_BLACK_BOX ( GrayscaleFillHole , bbtk::AtomicBlackBox ) ;
+    BBTK_NAME ( "GrayscaleFillHole" ) ;
+    BBTK_AUTHOR ( "Bill Lorensen" ) ;
+    BBTK_DESCRIPTION ( "GrayscaleFillholeImageFilter fills holes in a grayscale image.  Holes are local minima in the grayscale topography that are not connected to boundaries of the image. Gray level values adjacent to a hole are extrapolated across the hole.This filter is used to smooth over local minima without affecting the values of local maxima.  If you take the difference between the output of this filter and the original image and perhaps threshold the difference above a small value, you'll obtain a map of the local minima.This filter uses the itkGrayscaleGeodesicErodeImageFilter.  It provides its own input as the 'mask' input to the geodesic erosion.  The 'marker' image for the geodesic erosion is constructed such that boundary pixels match the boundary pixels of the input image and the interior pixels are set to the maximum pixel value in the input image. Geodesic morphology and the Fillhole algorithm is described in Chapter 6 of Pierre Soille's book 'Morphological Image Analysis: Principles and Applications', Second Edition, Springer, 2003.  A companion filter, Grayscale Grind Peak, removes peaks in grayscale images." ) ;
+    BBTK_CATEGORY ( "Filtering.Morphology" ) ;
+
+    // GENERATED DESCRPTION
+    
+BBTK_INPUT(GrayscaleFillHole , inputVolume , "inputVolume" , std::string, "");
+BBTK_INPUT(GrayscaleFillHole , outputVolume , "outputVolume" , std::string, "");
+
+    // EO GENERATED DESCRIPTION
+
+    BBTK_END_DESCRIBE_BLACK_BOX ( GrayscaleFillHole ) ;
+}
+
+#endif // __bbSlicerGrayscaleFillHole_h_INCLUDED__
+
+