From: Leonardo Florez-Valencia Date: Sun, 30 Oct 2016 02:53:07 +0000 (-0500) Subject: ... X-Git-Tag: v0.1~72 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=d6b52a06acc7f4303583aad084c368912dbf2068;p=cpPlugins.git ... --- diff --git a/appli/bash/CMakeLists.txt b/appli/bash/CMakeLists.txt index c945e6a..53037b8 100644 --- a/appli/bash/CMakeLists.txt +++ b/appli/bash/CMakeLists.txt @@ -10,6 +10,7 @@ INCLUDE_DIRECTORIES( SET( _bash_APPS + CreateRealConfig CreateInstances CreateDemanglers CreatePlugins diff --git a/appli/bash/Config.h.in b/appli/bash/Config.h.in index 953661b..859965d 100644 --- a/appli/bash/Config.h.in +++ b/appli/bash/Config.h.in @@ -22,6 +22,7 @@ #define cpPlugins_CONFIG_VECTORS "@cpPlugins_CONFIG_VECTORS@" #define cpPlugins_CONFIG_DIFFUSIONTENSORS "@cpPlugins_CONFIG_DIFFUSIONTENSORS@" #define cpPlugins_CONFIG_MATRICES "@cpPlugins_CONFIG_MATRICES@" +#define cpPlugins_ALL_CONFIGS "@cpPlugins_ALL_CONFIGS@" // ------------------------------------------------------------------------- #define cpPlugins_bash_OS_@CMAKE_SYSTEM_NAME@ diff --git a/appli/bash/CreateRealConfig.cxx b/appli/bash/CreateRealConfig.cxx new file mode 100644 index 0000000..e9737d5 --- /dev/null +++ b/appli/bash/CreateRealConfig.cxx @@ -0,0 +1,37 @@ +#include + +// ------------------------------------------------------------------------- +int main( int argc, char* argv[] ) +{ + // Get inputs + if( argc < 2 ) + { + std::cerr << "Usage: " << argv[ 0 ] << " output_file" << std::endl; + return( 1 ); + + } // fi + std::string output_filename = argv[ 1 ]; + + std::stringstream data; + data + << "#ifndef __cpPlugins__RealConfig__h__" << std::endl + << "#define __cpPlugins__RealConfig__h__" << std::endl + << std::endl; + + TStrings tokens; + cpPlugins_bash::Tokenize( tokens, cpPlugins_ALL_CONFIGS, ";" ); + for( auto t = tokens.begin( ); t != tokens.end( ); ++t ) + data << "#define " << *t << std::endl; + + data << std::endl << "#endif // __cpPlugins__RealConfig__h__" << std::endl; + if( !( cpPlugins_bash::Write( data.str( ), output_filename ) ) ) + { + std::cerr << "Error writing file." << std::endl; + return( 1 ); + + } // fi + + return( 0 ); +} + +// eof - $RCSfile$ diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 4d6f600..f10db6b 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -22,12 +22,12 @@ SUBDIRS(Instances) ## == Main library == ## ================== -FILE(WRITE ${CMAKE_CURRENT_BINARY_DIR}/cpPlugins/RealConfig.h "#ifndef __cpPlugins__RealConfig__h__\n") -FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/cpPlugins/RealConfig.h "#define __cpPlugins__RealConfig__h__\n\n") -FOREACH(_def ${cpPlugins_ALL_CONFIGS}) - FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/cpPlugins/RealConfig.h "#define ${_def}\n") -ENDFOREACH(_def) -FILE(APPEND ${CMAKE_CURRENT_BINARY_DIR}/cpPlugins/RealConfig.h "\n#endif // __cpPlugins__RealConfig__h__\n") +ADD_CUSTOM_COMMAND( + OUTPUT ${CMAKE_CURRENT_BINARY_DIR}/cpPlugins/RealConfig.h + COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_CURRENT_BINARY_DIR}/cpPlugins + COMMAND ${cpPlugins_bash_CreateRealConfig_APP} ${CMAKE_CURRENT_BINARY_DIR}/cpPlugins/RealConfig.h + DEPENDS ${cpPlugins_bash_CreateRealConfig_APP} + ) INCLUDE_DIRECTORIES(${CMAKE_CURRENT_BINARY_DIR}/Instances) CompileLibFromDir(cpPlugins SHARED cpPlugins ${CMAKE_CURRENT_BINARY_DIR}/cpPlugins/RealConfig.h) TARGET_LINK_LIBRARIES( diff --git a/plugins/ImageGradientFilters/FluxImageFilter.cxx b/plugins/ImageGradientFilters/FluxImageFilter.cxx index 806703d..8231a82 100644 --- a/plugins/ImageGradientFilters/FluxImageFilter.cxx +++ b/plugins/ImageGradientFilters/FluxImageFilter.cxx @@ -1,22 +1,26 @@ -#include +#include #include +#include -#include -#include +/* TODO + #include + #include -#include -#include -#include -#include + #include + #include + #include + #include +*/ // ------------------------------------------------------------------------- cpPluginsImageGradientFilters::FluxImageFilter:: FluxImageFilter( ) : Superclass( ) { - this->_ConfigureInput< cpPlugins::DataObjects::Image >( "Input", true, false ); - this->_ConfigureInput< cpPlugins::DataObjects::Image >( "Mask", false, false ); - this->_ConfigureOutput< cpPlugins::DataObjects::Image >( "Output" ); + typedef cpPlugins::DataObjects::Image _TImage; + this->_ConfigureInput< _TImage >( "Input", true, false ); + this->_ConfigureInput< _TImage >( "Mask", false, false ); + this->_ConfigureOutput< _TImage >( "Output" ); this->m_Parameters.ConfigureAsReal( "MinRadius" ); this->m_Parameters.ConfigureAsReal( "MaxRadius" ); @@ -39,9 +43,11 @@ cpPluginsImageGradientFilters::FluxImageFilter:: void cpPluginsImageGradientFilters::FluxImageFilter:: _GenerateData( ) { - auto o = this->GetInputData( "Input" ); - cpPlugins_Demangle_ImageCovariantVectors_Dims( o, _GD0 ); - else this->_Error( "Invalid input image." ); + /* TODO + auto o = this->GetInputData( "Input" ); + cpPlugins_Demangle_ImageCovariantVectors_Dims( o, _GD0 ); + else this->_Error( "Invalid input image." ); + */ } // ------------------------------------------------------------------------- @@ -49,27 +55,29 @@ template< class _TImage > void cpPluginsImageGradientFilters::FluxImageFilter:: _GD0( _TImage* image ) { - typedef typename _TImage::PixelType _TGradient; - typedef cpExtensions::Algorithms::FluxMedialness< _TImage > _TFunction; - typedef typename _TFunction::TOutput _TScalar; - typedef itk::Image< _TScalar, _TImage::ImageDimension > _TOutputImage; - typedef cpExtensions::Algorithms::ImageFunctionFilter< _TImage, _TOutputImage, _TFunction > _TFilter; + /* TODO + typedef typename _TImage::PixelType _TGradient; + typedef cpExtensions::Algorithms::FluxMedialness< _TImage > _TFunction; + typedef typename _TFunction::TOutput _TScalar; + typedef itk::Image< _TScalar, _TImage::ImageDimension > _TOutputImage; + typedef cpExtensions::Algorithms::ImageFunctionFilter< _TImage, _TOutputImage, _TFunction > _TFilter; - auto filter = this->_CreateITK< _TFilter >( ); - auto function = filter->GetFunction( ); - if( function == NULL ) - { - filter->SetFunction( _TFunction::New( ) ); - function = filter->GetFunction( ); + auto filter = this->_CreateITK< _TFilter >( ); + auto function = filter->GetFunction( ); + if( function == NULL ) + { + filter->SetFunction( _TFunction::New( ) ); + function = filter->GetFunction( ); - } // fi - function->SetMinRadius( this->m_Parameters.GetReal( "MinRadius" ) ); - function->SetMaxRadius( this->m_Parameters.GetReal( "MaxRadius" ) ); - function->SetRadiusStep( this->m_Parameters.GetReal( "RadiusStep" ) ); - function->SetRadialSampling( this->m_Parameters.GetUint( "RadialSampling" ) ); - filter->SetInput( image ); - filter->Update( ); - this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) ); + } // fi + function->SetMinRadius( this->m_Parameters.GetReal( "MinRadius" ) ); + function->SetMaxRadius( this->m_Parameters.GetReal( "MaxRadius" ) ); + function->SetRadiusStep( this->m_Parameters.GetReal( "RadiusStep" ) ); + function->SetRadialSampling( this->m_Parameters.GetUint( "RadialSampling" ) ); + filter->SetInput( image ); + filter->Update( ); + this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) ); + */ } // eof - $RCSfile$ diff --git a/plugins/ImageGradientFilters/FluxImageFilter.h b/plugins/ImageGradientFilters/FluxImageFilter.h index 321a8e9..2c4b4f8 100644 --- a/plugins/ImageGradientFilters/FluxImageFilter.h +++ b/plugins/ImageGradientFilters/FluxImageFilter.h @@ -1,7 +1,7 @@ #ifndef __cpPluginsImageGradientFilters__FluxImageFilter__h__ #define __cpPluginsImageGradientFilters__FluxImageFilter__h__ -#include +#include #include namespace cpPluginsImageGradientFilters @@ -19,7 +19,7 @@ namespace cpPluginsImageGradientFilters protected: template< class _TImage > - inline void _GD0( _TImage* image ); + inline void _GD0( _TImage* image ); }; } // ecapseman diff --git a/plugins/ImageGradientFilters/GulsunTekImageFilter.cxx b/plugins/ImageGradientFilters/GulsunTekImageFilter.cxx index 52525d9..4c46897 100644 --- a/plugins/ImageGradientFilters/GulsunTekImageFilter.cxx +++ b/plugins/ImageGradientFilters/GulsunTekImageFilter.cxx @@ -1,6 +1,6 @@ #include #include -#include +#include /* TODO #include @@ -17,9 +17,11 @@ cpPluginsImageGradientFilters::GulsunTekImageFilter:: GulsunTekImageFilter( ) : Superclass( ) { - this->_ConfigureInput< cpPlugins::DataObjects::Image >( "Input", true, false ); - this->_ConfigureInput< cpPlugins::DataObjects::Image >( "Mask", false, false ); - this->_ConfigureOutput< cpPlugins::DataObjects::Image >( "Output" ); + typedef cpPlugins::DataObjects::Image _TImage; + + this->_ConfigureInput< _TImage >( "Input", true, false ); + this->_ConfigureInput< _TImage >( "Mask", false, false ); + this->_ConfigureOutput< _TImage >( "Output" ); this->m_Parameters.ConfigureAsReal( "MinRadius" ); this->m_Parameters.ConfigureAsReal( "MaxRadius" ); @@ -42,9 +44,11 @@ cpPluginsImageGradientFilters::GulsunTekImageFilter:: void cpPluginsImageGradientFilters::GulsunTekImageFilter:: _GenerateData( ) { - auto o = this->GetInputData( "Input" ); - cpPlugins_Demangle_ImageCovariantVectors_Dims( o, _GD0 ); - else this->_Error( "Invalid input image." ); + /* TODO + auto o = this->GetInputData( "Input" ); + cpPlugins_Demangle_ImageCovariantVectors_Dims( o, _GD0 ); + else this->_Error( "Invalid input image." ); + */ } // ------------------------------------------------------------------------- @@ -52,39 +56,41 @@ template< class _TImage > void cpPluginsImageGradientFilters::GulsunTekImageFilter:: _GD0( _TImage* image ) { - typedef itk::Image< char, _TImage::ImageDimension > _TChar; - typedef itk::Image< short, _TImage::ImageDimension > _TShort; - typedef itk::Image< int, _TImage::ImageDimension > _TInt; - typedef itk::Image< long, _TImage::ImageDimension > _TLong; - typedef itk::Image< float, _TImage::ImageDimension > _TFloat; - typedef itk::Image< double, _TImage::ImageDimension > _TDouble; - typedef itk::Image< unsigned char, _TImage::ImageDimension > _TUChar; - typedef itk::Image< unsigned short, _TImage::ImageDimension > _TUShort; - typedef itk::Image< unsigned int, _TImage::ImageDimension > _TUInt; - typedef itk::Image< unsigned long, _TImage::ImageDimension > _TULong; + /* TODO + typedef itk::Image< char, _TImage::ImageDimension > _TChar; + typedef itk::Image< short, _TImage::ImageDimension > _TShort; + typedef itk::Image< int, _TImage::ImageDimension > _TInt; + typedef itk::Image< long, _TImage::ImageDimension > _TLong; + typedef itk::Image< float, _TImage::ImageDimension > _TFloat; + typedef itk::Image< double, _TImage::ImageDimension > _TDouble; + typedef itk::Image< unsigned char, _TImage::ImageDimension > _TUChar; + typedef itk::Image< unsigned short, _TImage::ImageDimension > _TUShort; + typedef itk::Image< unsigned int, _TImage::ImageDimension > _TUInt; + typedef itk::Image< unsigned long, _TImage::ImageDimension > _TULong; - auto m = this->GetInput( "Mask" ); - auto ci = m->GetITK< _TChar >( ); - auto si = m->GetITK< _TShort >( ); - auto ii = m->GetITK< _TInt >( ); - auto li = m->GetITK< _TLong >( ); - auto fi = m->GetITK< _TFloat >( ); - auto di = m->GetITK< _TDouble >( ); - auto uci = m->GetITK< _TUChar >( ); - auto usi = m->GetITK< _TUShort >( ); - auto uii = m->GetITK< _TUInt >( ); - auto uli = m->GetITK< _TULong >( ); - if ( ci != NULL ) this->_GD1( image, ci ); - else if( si != NULL ) this->_GD1( image, si ); - else if( ii != NULL ) this->_GD1( image, ii ); - else if( li != NULL ) this->_GD1( image, li ); - else if( fi != NULL ) this->_GD1( image, fi ); - else if( di != NULL ) this->_GD1( image, di ); - else if( uci != NULL ) this->_GD1( image, uci ); - else if( usi != NULL ) this->_GD1( image, usi ); - else if( uii != NULL ) this->_GD1( image, uii ); - else if( uli != NULL ) this->_GD1( image, uli ); - else this->_GD1( image, ci ); + auto m = this->GetInput( "Mask" ); + auto ci = m->GetITK< _TChar >( ); + auto si = m->GetITK< _TShort >( ); + auto ii = m->GetITK< _TInt >( ); + auto li = m->GetITK< _TLong >( ); + auto fi = m->GetITK< _TFloat >( ); + auto di = m->GetITK< _TDouble >( ); + auto uci = m->GetITK< _TUChar >( ); + auto usi = m->GetITK< _TUShort >( ); + auto uii = m->GetITK< _TUInt >( ); + auto uli = m->GetITK< _TULong >( ); + if ( ci != NULL ) this->_GD1( image, ci ); + else if( si != NULL ) this->_GD1( image, si ); + else if( ii != NULL ) this->_GD1( image, ii ); + else if( li != NULL ) this->_GD1( image, li ); + else if( fi != NULL ) this->_GD1( image, fi ); + else if( di != NULL ) this->_GD1( image, di ); + else if( uci != NULL ) this->_GD1( image, uci ); + else if( usi != NULL ) this->_GD1( image, usi ); + else if( uii != NULL ) this->_GD1( image, uii ); + else if( uli != NULL ) this->_GD1( image, uli ); + else this->_GD1( image, ci ); + */ } // ------------------------------------------------------------------------- @@ -92,29 +98,31 @@ template< class _TImage, class _TMask > void cpPluginsImageGradientFilters::GulsunTekImageFilter:: _GD1( _TImage* image, _TMask* mask ) { - typedef typename _TImage::PixelType _TGradient; - typedef cpExtensions::Algorithms::GulsunTekMedialness< _TImage, _TMask > _TFunction; - typedef typename _TFunction::TOutput _TScalar; - typedef itk::Image< _TScalar, _TImage::ImageDimension > _TOutputImage; - typedef cpExtensions::Algorithms::ImageFunctionFilter< _TImage, _TOutputImage, _TFunction > _TFilter; + /* TODO + typedef typename _TImage::PixelType _TGradient; + typedef cpExtensions::Algorithms::GulsunTekMedialness< _TImage, _TMask > _TFunction; + typedef typename _TFunction::TOutput _TScalar; + typedef itk::Image< _TScalar, _TImage::ImageDimension > _TOutputImage; + typedef cpExtensions::Algorithms::ImageFunctionFilter< _TImage, _TOutputImage, _TFunction > _TFilter; - auto filter = this->_CreateITK< _TFilter >( ); - auto function = filter->GetFunction( ); - if( function == NULL ) - { - filter->SetFunction( _TFunction::New( ) ); - function = filter->GetFunction( ); + auto filter = this->_CreateITK< _TFilter >( ); + auto function = filter->GetFunction( ); + if( function == NULL ) + { + filter->SetFunction( _TFunction::New( ) ); + function = filter->GetFunction( ); - } // fi - function->SetMinRadius( this->m_Parameters.GetReal( "MinRadius" ) ); - function->SetMaxRadius( this->m_Parameters.GetReal( "MaxRadius" ) ); - function->SetProfileSampling( this->m_Parameters.GetUint( "ProfileSampling" ) ); - function->SetRadialSampling( this->m_Parameters.GetUint( "RadialSampling" ) ); - filter->SetInput( image ); - if( mask != NULL ) - function->SetMask( mask ); - filter->Update( ); - this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) ); + } // fi + function->SetMinRadius( this->m_Parameters.GetReal( "MinRadius" ) ); + function->SetMaxRadius( this->m_Parameters.GetReal( "MaxRadius" ) ); + function->SetProfileSampling( this->m_Parameters.GetUint( "ProfileSampling" ) ); + function->SetRadialSampling( this->m_Parameters.GetUint( "RadialSampling" ) ); + filter->SetInput( image ); + if( mask != NULL ) + function->SetMask( mask ); + filter->Update( ); + this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) ); + */ } // eof - $RCSfile$ diff --git a/plugins/ImageGradientFilters/MFluxImageFilter.cxx b/plugins/ImageGradientFilters/MFluxImageFilter.cxx index d166118..8575a59 100644 --- a/plugins/ImageGradientFilters/MFluxImageFilter.cxx +++ b/plugins/ImageGradientFilters/MFluxImageFilter.cxx @@ -1,22 +1,26 @@ -#include +#include #include +#include -#include -#include +/* TODO + #include + #include -#include -#include -#include -#include + #include + #include + #include + #include +*/ // ------------------------------------------------------------------------- cpPluginsImageGradientFilters::MFluxImageFilter:: MFluxImageFilter( ) : Superclass( ) { - this->_ConfigureInput< cpPlugins::DataObjects::Image >( "Input", true, false ); - this->_ConfigureInput< cpPlugins::DataObjects::Image >( "Mask", false, false ); - this->_ConfigureOutput< cpPlugins::DataObjects::Image >( "Output" ); + typedef cpPlugins::DataObjects::Image _TImage; + this->_ConfigureInput< _TImage >( "Input", true, false ); + this->_ConfigureInput< _TImage >( "Mask", false, false ); + this->_ConfigureOutput< _TImage >( "Output" ); this->m_Parameters.ConfigureAsReal( "MinRadius" ); this->m_Parameters.ConfigureAsReal( "MaxRadius" ); @@ -39,9 +43,11 @@ cpPluginsImageGradientFilters::MFluxImageFilter:: void cpPluginsImageGradientFilters::MFluxImageFilter:: _GenerateData( ) { - auto o = this->GetInputData( "Input" ); - cpPlugins_Demangle_ImageCovariantVectors_Dims( o, _GD0 ); - else this->_Error( "Invalid input image." ); + /* TODO + auto o = this->GetInputData( "Input" ); + cpPlugins_Demangle_ImageCovariantVectors_Dims( o, _GD0 ); + else this->_Error( "Invalid input image." ); + */ } // ------------------------------------------------------------------------- @@ -49,27 +55,29 @@ template< class _TImage > void cpPluginsImageGradientFilters::MFluxImageFilter:: _GD0( _TImage* image ) { - typedef typename _TImage::PixelType _TGradient; - typedef cpExtensions::Algorithms::MFluxMedialness< _TImage > _TFunction; - typedef typename _TFunction::TOutput _TScalar; - typedef itk::Image< _TScalar, _TImage::ImageDimension > _TOutputImage; - typedef cpExtensions::Algorithms::ImageFunctionFilter< _TImage, _TOutputImage, _TFunction > _TFilter; + /* TODO + typedef typename _TImage::PixelType _TGradient; + typedef cpExtensions::Algorithms::MFluxMedialness< _TImage > _TFunction; + typedef typename _TFunction::TOutput _TScalar; + typedef itk::Image< _TScalar, _TImage::ImageDimension > _TOutputImage; + typedef cpExtensions::Algorithms::ImageFunctionFilter< _TImage, _TOutputImage, _TFunction > _TFilter; - auto filter = this->_CreateITK< _TFilter >( ); - auto function = filter->GetFunction( ); - if( function == NULL ) - { - filter->SetFunction( _TFunction::New( ) ); - function = filter->GetFunction( ); + auto filter = this->_CreateITK< _TFilter >( ); + auto function = filter->GetFunction( ); + if( function == NULL ) + { + filter->SetFunction( _TFunction::New( ) ); + function = filter->GetFunction( ); - } // fi - function->SetMinRadius( this->m_Parameters.GetReal( "MinRadius" ) ); - function->SetMaxRadius( this->m_Parameters.GetReal( "MaxRadius" ) ); - function->SetRadiusStep( this->m_Parameters.GetReal( "RadiusStep" ) ); - function->SetRadialSampling( this->m_Parameters.GetUint( "RadialSampling" ) ); - filter->SetInput( image ); - filter->Update( ); - this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) ); + } // fi + function->SetMinRadius( this->m_Parameters.GetReal( "MinRadius" ) ); + function->SetMaxRadius( this->m_Parameters.GetReal( "MaxRadius" ) ); + function->SetRadiusStep( this->m_Parameters.GetReal( "RadiusStep" ) ); + function->SetRadialSampling( this->m_Parameters.GetUint( "RadialSampling" ) ); + filter->SetInput( image ); + filter->Update( ); + this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) ); + */ } // eof - $RCSfile$ diff --git a/plugins/ImageGradientFilters/MFluxImageFilter.h b/plugins/ImageGradientFilters/MFluxImageFilter.h index 938ffd9..58fb656 100644 --- a/plugins/ImageGradientFilters/MFluxImageFilter.h +++ b/plugins/ImageGradientFilters/MFluxImageFilter.h @@ -1,7 +1,7 @@ #ifndef __cpPluginsImageGradientFilters__MFluxImageFilter__h__ #define __cpPluginsImageGradientFilters__MFluxImageFilter__h__ -#include +#include #include namespace cpPluginsImageGradientFilters @@ -19,7 +19,7 @@ namespace cpPluginsImageGradientFilters protected: template< class _TImage > - inline void _GD0( _TImage* image ); + inline void _GD0( _TImage* image ); }; } // ecapseman diff --git a/plugins/ImageParaMorphologyFilters/BinaryDilateParaImageFilter.cxx b/plugins/ImageParaMorphologyFilters/BinaryDilateParaImageFilter.cxx index 6af981b..3f11eae 100644 --- a/plugins/ImageParaMorphologyFilters/BinaryDilateParaImageFilter.cxx +++ b/plugins/ImageParaMorphologyFilters/BinaryDilateParaImageFilter.cxx @@ -1,19 +1,23 @@ -#include +#include #include -#include -#include -#include -#include -#include +/* TODO + #include + #include + #include + #include + #include +*/ // ------------------------------------------------------------------------- cpPluginsImageParaMorphologyFilters::BinaryDilateParaImageFilter:: BinaryDilateParaImageFilter( ) : 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( "Radius" ); this->m_Parameters.ConfigureAsBool( "Circular" ); this->m_Parameters.ConfigureAsBool( "UseImageSpacing" ); @@ -33,9 +37,11 @@ cpPluginsImageParaMorphologyFilters::BinaryDilateParaImageFilter:: void cpPluginsImageParaMorphologyFilters::BinaryDilateParaImageFilter:: _GenerateData( ) { - auto o = this->GetInputData( "Input" ); - cpPlugins_Demangle_ImageScalars_Dims( o, _GD0 ); - else this->_Error( "No valid input image." ); + /* TODO + auto o = this->GetInputData( "Input" ); + cpPlugins_Demangle_ImageScalars_Dims( o, _GD0 ); + else this->_Error( "No valid input image." ); + */ } // ------------------------------------------------------------------------- @@ -43,15 +49,17 @@ template< class _TImage > void cpPluginsImageParaMorphologyFilters::BinaryDilateParaImageFilter:: _GD0( _TImage* image ) { - typedef itk::BinaryDilateParaImageFilter< _TImage > _TFilter; - - auto filter = this->_CreateITK< _TFilter >( ); - filter->SetInput( image ); - filter->SetRadius( this->m_Parameters.GetReal( "Radius" ) ); - filter->SetCircular( this->m_Parameters.GetBool( "Circular" ) ); - filter->SetUseImageSpacing( this->m_Parameters.GetBool( "UseImageSpacing" ) ); - filter->Update( ); - this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) ); + /* TODO + typedef itk::BinaryDilateParaImageFilter< _TImage > _TFilter; + + auto filter = this->_CreateITK< _TFilter >( ); + filter->SetInput( image ); + filter->SetRadius( this->m_Parameters.GetReal( "Radius" ) ); + filter->SetCircular( this->m_Parameters.GetBool( "Circular" ) ); + filter->SetUseImageSpacing( this->m_Parameters.GetBool( "UseImageSpacing" ) ); + filter->Update( ); + this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) ); + */ } // eof - $RCSfile$ diff --git a/plugins/ImageParaMorphologyFilters/BinaryDilateParaImageFilter.h b/plugins/ImageParaMorphologyFilters/BinaryDilateParaImageFilter.h index 89dbea5..67615c0 100644 --- a/plugins/ImageParaMorphologyFilters/BinaryDilateParaImageFilter.h +++ b/plugins/ImageParaMorphologyFilters/BinaryDilateParaImageFilter.h @@ -1,7 +1,7 @@ #ifndef __cpPluginsImageParaMorphologyFilters__BinaryDilateParaImageFilter__h__ #define __cpPluginsImageParaMorphologyFilters__BinaryDilateParaImageFilter__h__ -#include +#include #include namespace cpPluginsImageParaMorphologyFilters @@ -19,7 +19,7 @@ namespace cpPluginsImageParaMorphologyFilters protected: template< class _TImage > - inline void _GD0( _TImage* image ); + inline void _GD0( _TImage* image ); }; } // ecapseman diff --git a/plugins/ImageParaMorphologyFilters/BinaryErodeParaImageFilter.cxx b/plugins/ImageParaMorphologyFilters/BinaryErodeParaImageFilter.cxx index c03f7a6..c123e19 100644 --- a/plugins/ImageParaMorphologyFilters/BinaryErodeParaImageFilter.cxx +++ b/plugins/ImageParaMorphologyFilters/BinaryErodeParaImageFilter.cxx @@ -1,19 +1,23 @@ -#include +#include #include -#include -#include -#include -#include -#include +/* TODO + #include + #include + #include + #include + #include +*/ // ------------------------------------------------------------------------- cpPluginsImageParaMorphologyFilters::BinaryErodeParaImageFilter:: BinaryErodeParaImageFilter( ) : 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( "Radius" ); this->m_Parameters.ConfigureAsBool( "Circular" ); this->m_Parameters.ConfigureAsBool( "UseImageSpacing" ); @@ -33,9 +37,11 @@ cpPluginsImageParaMorphologyFilters::BinaryErodeParaImageFilter:: void cpPluginsImageParaMorphologyFilters::BinaryErodeParaImageFilter:: _GenerateData( ) { - auto o = this->GetInputData( "Input" ); - cpPlugins_Demangle_ImageScalars_Dims( o, _GD0 ); - else this->_Error( "No valid input image." ); + /* TODO + auto o = this->GetInputData( "Input" ); + cpPlugins_Demangle_ImageScalars_Dims( o, _GD0 ); + else this->_Error( "No valid input image." ); + */ } // ------------------------------------------------------------------------- @@ -43,15 +49,17 @@ template< class _TImage > void cpPluginsImageParaMorphologyFilters::BinaryErodeParaImageFilter:: _GD0( _TImage* image ) { - typedef itk::BinaryErodeParaImageFilter< _TImage > _TFilter; - - auto filter = this->_CreateITK< _TFilter >( ); - filter->SetInput( image ); - filter->SetRadius( this->m_Parameters.GetReal( "Radius" ) ); - filter->SetCircular( this->m_Parameters.GetBool( "Circular" ) ); - filter->SetUseImageSpacing( this->m_Parameters.GetBool( "UseImageSpacing" ) ); - filter->Update( ); - this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) ); + /* TODO + typedef itk::BinaryErodeParaImageFilter< _TImage > _TFilter; + + auto filter = this->_CreateITK< _TFilter >( ); + filter->SetInput( image ); + filter->SetRadius( this->m_Parameters.GetReal( "Radius" ) ); + filter->SetCircular( this->m_Parameters.GetBool( "Circular" ) ); + filter->SetUseImageSpacing( this->m_Parameters.GetBool( "UseImageSpacing" ) ); + filter->Update( ); + this->GetOutput( "Output" )->SetITK( filter->GetOutput( ) ); + */ } // eof - $RCSfile$ diff --git a/plugins/ImageParaMorphologyFilters/BinaryErodeParaImageFilter.h b/plugins/ImageParaMorphologyFilters/BinaryErodeParaImageFilter.h index 77eabf7..2e28ac6 100644 --- a/plugins/ImageParaMorphologyFilters/BinaryErodeParaImageFilter.h +++ b/plugins/ImageParaMorphologyFilters/BinaryErodeParaImageFilter.h @@ -1,7 +1,7 @@ #ifndef __cpPluginsImageParaMorphologyFilters__BinaryErodeParaImageFilter__h__ #define __cpPluginsImageParaMorphologyFilters__BinaryErodeParaImageFilter__h__ -#include +#include #include namespace cpPluginsImageParaMorphologyFilters @@ -19,7 +19,7 @@ namespace cpPluginsImageParaMorphologyFilters protected: template< class _TImage > - inline void _GD0( _TImage* image ); + inline void _GD0( _TImage* image ); }; } // ecapseman