]> Creatis software - cpPlugins.git/blobdiff - plugins/ImageThresholdFilters/UnaryThresholdImageFilter.cxx
...
[cpPlugins.git] / plugins / ImageThresholdFilters / UnaryThresholdImageFilter.cxx
index 97754e7aaa3879aa1cf4a56380fb10458bf68b15..cd16ed3a243ce3e6de71ef48346598eb1d006f0e 100644 (file)
@@ -1,17 +1,16 @@
-#include <plugins/ImageThresholdFilters/UnaryThresholdImageFilter.h>
+#include <ImageThresholdFilters/UnaryThresholdImageFilter.h>
 #include <cpPlugins/DataObjects/Image.h>
 
 #include <cpExtensions/Algorithms/UnaryThresholdImageFilter.h>
-#include <cpExtensions/Algorithms/UnaryThresholdImageFilter.hxx>
-#include <itkUnaryFunctorImageFilter.hxx>
 
 // -------------------------------------------------------------------------
 cpPluginsImageThresholdFilters::UnaryThresholdImageFilter::
 UnaryThresholdImageFilter( )
   : Superclass( )
 {
-  this->_ConfigureInput< cpPlugins::DataObjects::Image >( "Input", true, false );
-  this->_ConfigureOutput< cpPlugins::DataObjects::Image >( "Output" );
+  typedef cpPlugins::DataObjects::Image _TImage;
+  this->_ConfigureInput< _TImage >( "Input", true, false );
+  this->_ConfigureOutput< _TImage >( "Output" );
 
   this->m_Parameters.ConfigureAsReal( "Threshold" );
   this->m_Parameters.ConfigureAsReal( "InsideValue" );
@@ -34,9 +33,11 @@ cpPluginsImageThresholdFilters::UnaryThresholdImageFilter::
 void cpPluginsImageThresholdFilters::UnaryThresholdImageFilter::
 _GenerateData( )
 {
-  auto o = this->GetInputData( "Input" );
-  cpPlugins_Demangle_ImageScalars_Dims( o, _GD0 );
-  else this->_Error( "Invalid input image." );
+  /* TODO
+     auto o = this->GetInputData( "Input" );
+     cpPlugins_Demangle_ImageScalars_Dims( o, _GD0 );
+     else this->_Error( "Invalid input image." );
+  */
 }
 
 // -------------------------------------------------------------------------
@@ -44,21 +45,23 @@ template< class _TImage >
 void cpPluginsImageThresholdFilters::UnaryThresholdImageFilter::
 _GD0( _TImage* image )
 {
-  typedef
-    cpExtensions::Algorithms::UnaryThresholdImageFilter< _TImage >
-    _TFilter;
+  /* TODO
+     typedef
+     cpExtensions::Algorithms::UnaryThresholdImageFilter< _TImage >
+     _TFilter;
 
-  // Configure filter
-  _TFilter* filter = this->_CreateITK< _TFilter >( );
-  filter->SetInput( image );
-  filter->SetThreshold( this->m_Parameters.GetReal( "Threshold" ) );
-  filter->SetInsideValue( this->m_Parameters.GetReal( "InsideValue" ) );
-  filter->SetOutsideValue( this->m_Parameters.GetReal( "OutsideValue" ) );
-  filter->SetStrict( this->m_Parameters.GetBool( "Strict" ) );
-  filter->Update( );
+     // Configure filter
+     _TFilter* filter = this->_CreateITK< _TFilter >( );
+     filter->SetInput( image );
+     filter->SetThreshold( this->m_Parameters.GetReal( "Threshold" ) );
+     filter->SetInsideValue( this->m_Parameters.GetReal( "InsideValue" ) );
+     filter->SetOutsideValue( this->m_Parameters.GetReal( "OutsideValue" ) );
+     filter->SetStrict( this->m_Parameters.GetBool( "Strict" ) );
+     filter->Update( );
 
-  // Connect output
-  this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) );
+     // Connect output
+     this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) );
+  */
 }
 
 // eof - $RCSfile$