]> Creatis software - cpPlugins.git/blobdiff - lib/cpExtensions/Algorithms/MacheteImageFilter.h
Merge branch 'master' of ssh://git.creatis.insa-lyon.fr/cpPlugins
[cpPlugins.git] / lib / cpExtensions / Algorithms / MacheteImageFilter.h
diff --git a/lib/cpExtensions/Algorithms/MacheteImageFilter.h b/lib/cpExtensions/Algorithms/MacheteImageFilter.h
new file mode 100644 (file)
index 0000000..4dde2dc
--- /dev/null
@@ -0,0 +1,62 @@
+// -------------------------------------------------------------------------
+// @author Jose Luis Guzman (cycopepe@gmail.com)
+// -------------------------------------------------------------------------
+
+
+#ifndef __CPEXTENSIONS__ALGORITHMS__MACHETEIMAGEFILTER__H__
+#define __CPEXTENSIONS__ALGORITHMS__MACHETEIMAGEFILTER__H__
+
+#include <cpExtensions/cpExtensions_Export.h>
+
+#include <itkImageToImageFilter.h>
+
+namespace cpExtensions
+{
+  namespace Algorithms
+  {
+    template< class I, class O>
+    class MacheteImageFilter :public itk::ImageToImageFilter < I, O >
+    {
+    public:
+      /** Standard class typedefs. */
+      typedef MacheteImageFilter             Self;
+
+      typedef itk::ImageToImageFilter< I, O > Superclass;
+      typedef itk::SmartPointer< Self >        Pointer;
+
+      /** Method for creation through the object factory. */
+      itkNewMacro(Self);
+
+      /** Run-time type information (and related methods). */
+      itkTypeMacro(MacheteImageFilter, ImageToImageFilter);
+
+      void SetRadius(double radius);
+      void SetPoint(itk::Point<double, 3> point);
+
+    protected:
+      MacheteImageFilter(){}
+      ~MacheteImageFilter(){}
+
+      /** Does the real work. */
+      virtual void GenerateData();
+
+
+    private:
+      MacheteImageFilter(const Self &); //purposely not implemented
+      void operator=(const Self &);  //purposely not implemented
+
+      double radius;
+      itk::Point<double, 3> point;
+    };
+
+  } // ecapseman
+
+} // ecapseman
+
+
+#ifndef ITK_MANUAL_INSTANTIATION
+#include <cpExtensions/Algorithms/MacheteImageFilter.hxx>
+#endif
+
+
+#endif // __CPEXTENSIONS__ALGORITHMS__MACHETEIMAGEFILTER__H__
\ No newline at end of file