From 826a318db2e9b41fbd865e41ebb5906efdefbb02 Mon Sep 17 00:00:00 2001 From: Leonardo Florez-Valencia Date: Wed, 6 Apr 2016 19:27:57 -0500 Subject: [PATCH] more experiments... --- CMakeLists.txt | 2 + lib/CMakeLists.txt | 4 + ...tsAndBifurcationsFromMinimumSpanningTree.h | 6 +- ...AndBifurcationsFromMinimumSpanningTree.hxx | 5 +- .../Base/ExtractPathFromMinimumSpanningTree.h | 10 ++- .../ExtractPathFromMinimumSpanningTree.hxx | 1 + ...tsAndBifurcationsFromMinimumSpanningTree.h | 15 ---- ...AndBifurcationsFromMinimumSpanningTree.hxx | 10 ++- lib/fpa_Instances/CMakeLists.txt | 77 +++++++++++++++++++ lib/fpa_Instances/Filters.i | 14 ++++ lib/fpa_Instances/Instances.i | 23 ++++++ lib/fpa_Instances/Observers.i | 15 ++++ plugins/fpa/BaseImageFilter.cxx | 3 +- plugins/fpa/BaseImageFilter.h | 2 +- plugins/fpa/BaseImageFilter.hxx | 17 ++-- plugins/fpa/CMakeLists.txt | 25 +++--- ...AndBifurcationsFromMinimumSpanningTree.cxx | 9 ++- .../ExtractPathFromMinimumSpanningTree.cxx | 6 +- plugins/fpa/ImageDijkstra.cxx | 12 +-- plugins/fpa/ImageRegionGrow.cxx | 11 ++- plugins/fpa/MinimumSpanningTree.cxx | 21 +---- plugins/fpa/MinimumSpanningTree.h | 1 - 22 files changed, 203 insertions(+), 86 deletions(-) create mode 100644 lib/fpa_Instances/CMakeLists.txt create mode 100644 lib/fpa_Instances/Filters.i create mode 100644 lib/fpa_Instances/Instances.i create mode 100644 lib/fpa_Instances/Observers.i diff --git a/CMakeLists.txt b/CMakeLists.txt index b246500..785164b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -88,6 +88,8 @@ INCLUDE_DIRECTORIES( ${PROJECT_BINARY_DIR} ${PROJECT_SOURCE_DIR}/lib ${PROJECT_BINARY_DIR}/lib + ${PROJECT_SOURCE_DIR}/lib/fpa_Instances + ${PROJECT_BINARY_DIR}/lib/fpa_Instances ${PROJECT_SOURCE_DIR}/plugins ${PROJECT_BINARY_DIR}/plugins ) diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 7e4b783..3efe1bc 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -106,4 +106,8 @@ INSTALL( DESTINATION include/fpa ) +SUBDIRS( + fpa_Instances + ) + ## eof - $RCSfile$ diff --git a/lib/fpa/Base/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.h b/lib/fpa/Base/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.h index d6e97af..eaabf5a 100644 --- a/lib/fpa/Base/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.h +++ b/lib/fpa/Base/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.h @@ -3,7 +3,7 @@ #include #include -#include +#include namespace fpa { @@ -24,7 +24,9 @@ namespace fpa typedef _TMST TMinimumSpanningTree; typedef typename _TMST::TVertex TVertex; - typedef itk::SimpleDataObjectDecorator< std::vector< TVertex > > TVertices; + typedef + cpExtensions::DataStructures::ImageIndexesContainer< TVertex::Dimension > + TVertices; public: itkTypeMacro( diff --git a/lib/fpa/Base/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.hxx b/lib/fpa/Base/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.hxx index 844d60c..af63bb0 100644 --- a/lib/fpa/Base/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.hxx +++ b/lib/fpa/Base/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.hxx @@ -172,7 +172,6 @@ GenerateData( ) // 2.4.2. A collision has been reached last_collision = *pIt; collisions->Get( ).push_back( *pIt ); - std::cout << *pIt << std::endl; inCollision = true; } else @@ -199,6 +198,10 @@ GenerateData( ) } // elihw } // rof + + endpoints->SetReferenceImage( mst ); + bifurcations->SetReferenceImage( mst ); + collisions->SetReferenceImage( mst ); } #endif // __FPA__BASE__EXTRACTENDPOINTSANDBIFURCATIONSFROMMINIMUMSPANNINGTREE__HXX__ diff --git a/lib/fpa/Base/ExtractPathFromMinimumSpanningTree.h b/lib/fpa/Base/ExtractPathFromMinimumSpanningTree.h index e29a87d..4566077 100644 --- a/lib/fpa/Base/ExtractPathFromMinimumSpanningTree.h +++ b/lib/fpa/Base/ExtractPathFromMinimumSpanningTree.h @@ -3,7 +3,7 @@ #include #include -#include +#include namespace fpa { @@ -21,9 +21,11 @@ namespace fpa typedef itk::SmartPointer< Self > Pointer; typedef itk::SmartPointer< const Self > ConstPointer; - typedef T TMinimumSpanningTree; - typedef typename T::TVertex TVertex; - typedef itk::PolyLineParametricPath< TVertex::Dimension > TPath; + typedef T TMinimumSpanningTree; + typedef typename T::TVertex TVertex; + typedef + cpExtensions::DataStructures::PolyLineParametricPath< TVertex::Dimension > + TPath; public: itkNewMacro( Self ); diff --git a/lib/fpa/Base/ExtractPathFromMinimumSpanningTree.hxx b/lib/fpa/Base/ExtractPathFromMinimumSpanningTree.hxx index c44f41a..400642c 100644 --- a/lib/fpa/Base/ExtractPathFromMinimumSpanningTree.hxx +++ b/lib/fpa/Base/ExtractPathFromMinimumSpanningTree.hxx @@ -62,6 +62,7 @@ GenerateData( ) path->Initialize( ); for( auto i = lst.begin( ); i != lst.end( ); ++i ) path->AddVertex( *i ); + path->SetReferenceImage( tree ); } #endif // __FPA__BASE__EXTRACTPATHFROMMINIMUMSPANNINGTREE__HXX__ diff --git a/lib/fpa/Image/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.h b/lib/fpa/Image/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.h index 4ad643a..9fd6c88 100644 --- a/lib/fpa/Image/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.h +++ b/lib/fpa/Image/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.h @@ -3,10 +3,6 @@ #include -#include -#include -#include - namespace fpa { namespace Image @@ -68,17 +64,6 @@ namespace fpa virtual void _Tmp( ) override { - /* TODO - static unsigned int i = 0; - std::stringstream s; - s << "marks_" << i << ".mhd"; - i++; - typename itk::ImageFileWriter< TMarkImage >::Pointer w = - itk::ImageFileWriter< TMarkImage >::New( ); - w->SetInput( this->m_MarkImage ); - w->SetFileName( s.str( ) ); - w->Update( ); - */ } private: diff --git a/lib/fpa/Image/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.hxx b/lib/fpa/Image/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.hxx index d2bc828..16d03e8 100644 --- a/lib/fpa/Image/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.hxx +++ b/lib/fpa/Image/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.hxx @@ -116,6 +116,8 @@ _MarkSphere( const unsigned long& l ) { + double rr = r * double( 1.5 ); + // Get marking region auto rreg = this->m_MarkImage->GetRequestedRegion( ); auto spac = this->m_MarkImage->GetSpacing( ); @@ -126,7 +128,7 @@ _MarkSphere( bool all = false; for( unsigned int d = 0; d < _TImage::ImageDimension; ++d ) { - unsigned long s = std::ceil( r / double( spac[ d ] ) ); + unsigned long s = std::ceil( rr / double( spac[ d ] ) ); if( s < 3 ) { s = 3; @@ -158,9 +160,9 @@ _MarkSphere( { typename _TImage::PointType pnt; this->m_MarkImage->TransformIndexToPhysicalPoint( spIt.GetIndex( ), pnt ); - // TODO: if( double( pnt.EuclideanDistanceTo( c ) ) <= r || all ) - // TODO: if( spIt.Get( ) == 0 ) - spIt.Set( l ); + if( double( pnt.EuclideanDistanceTo( c ) ) <= rr || all ) + if( spIt.Get( ) == 0 ) + spIt.Set( l ); } // rof } diff --git a/lib/fpa_Instances/CMakeLists.txt b/lib/fpa_Instances/CMakeLists.txt new file mode 100644 index 0000000..d9fe125 --- /dev/null +++ b/lib/fpa_Instances/CMakeLists.txt @@ -0,0 +1,77 @@ +FILE( + GLOB libs_DEFS RELATIVE + "${CMAKE_CURRENT_SOURCE_DIR}" + "${CMAKE_CURRENT_SOURCE_DIR}/*.i" + ) + +SET(aux_ALL_INSTANCES) +FOREACH(i ${libs_DEFS}) + GET_FILENAME_COMPONENT(l_DEF ${i} NAME_WE) + SET(i_FILE "${CMAKE_CURRENT_SOURCE_DIR}/${l_DEF}.i") + SET(h_FILE "${CMAKE_CURRENT_BINARY_DIR}/${l_DEF}.h") + SET(s_FILE "${CMAKE_CURRENT_BINARY_DIR}/${l_DEF}.cxx") + SET(o_FILE "${CMAKE_CURRENT_SOURCE_DIR}/${l_DEF}_extra.cxx") + SET(l_NAME "fpa_${l_DEF}") + SET(aux_ALL_INSTANCES ${aux_ALL_INSTANCES} ${l_NAME}) + ADD_CUSTOM_COMMAND( + OUTPUT ${h_FILE} ${s_FILE} + DEPENDS ${cpPlugins_CreateInstances} ${i_FILE} + COMMAND ${cpPlugins_CreateInstances} ${i_FILE} ${l_NAME} ${h_FILE} ${s_FILE} + ) + IF(EXISTS ${o_FILE}) + ADD_LIBRARY(${l_NAME} SHARED ${s_FILE} ${o_FILE}) + ELSE(EXISTS ${o_FILE}) + ADD_LIBRARY(${l_NAME} SHARED ${s_FILE}) + ENDIF(EXISTS ${o_FILE}) + SET_TARGET_PROPERTIES( + ${l_NAME} PROPERTIES + VERSION "${prj_VER}" + SOVERSION "${prj_sVER}" + ) + GENERATE_EXPORT_HEADER( + ${l_NAME} + BASE_NAME ${l_NAME} + EXPORT_MACRO_NAME ${l_NAME}_EXPORT + EXPORT_FILE_NAME ${CMAKE_CURRENT_BINARY_DIR}/${l_NAME}_Export.h + STATIC_DEFINE ${l_NAME}_BUILT_AS_STATIC + ) +ENDFOREACH(i) + +SET( + fpa_ALL_INSTANCES + ${aux_ALL_INSTANCES} + CACHE STRING "All instances libraries." + ) + +## Target links +TARGET_LINK_LIBRARIES(fpa_Instances ${cpPlugins_LIBRARY} ${cpPlugins_ALL_INSTANCES_LIBRARIES}) +TARGET_LINK_LIBRARIES(fpa_Filters fpa_Instances) +TARGET_LINK_LIBRARIES(fpa_Observers fpa_Filters) + +# TARGET_LINK_LIBRARIES(fpa_Transforms ${ITK_LIBRARIES} fpa_Base) +# TARGET_LINK_LIBRARIES(fpa_Paths fpa_Base) +# TARGET_LINK_LIBRARIES(fpa_Mesh fpa_Base) +# TARGET_LINK_LIBRARIES(fpa_Image fpa_Base) +# TARGET_LINK_LIBRARIES(fpa_ImageIterators ${ITK_LIBRARIES} fpa_Image) +# TARGET_LINK_LIBRARIES(fpa_ImageFiltersBase fpa_Image) +# TARGET_LINK_LIBRARIES(fpa_InPlaceImageFiltersBase fpa_ImageFiltersBase) +# TARGET_LINK_LIBRARIES(fpa_ImageITK2VTK fpa_ImageFiltersBase ${VTK_LIBRARIES}) +# TARGET_LINK_LIBRARIES(fpa_ThresholdFilters fpa_InPlaceImageFiltersBase fpa_ImageIterators) +# TARGET_LINK_LIBRARIES(fpa_DistanceMapFilters fpa_ThresholdFilters) +# TARGET_LINK_LIBRARIES(fpa_ResamplingFilters fpa_ImageFiltersBase fpa_ImageIterators fpa_Transforms) +# TARGET_LINK_LIBRARIES(fpa_GaussianImageFilters fpa_ImageFiltersBase fpa_ImageIterators) +# TARGET_LINK_LIBRARIES(fpa_ImageIO fpa_ImageFiltersBase fpa_ImageIterators) + +# INSTALL( +# TARGETS ${l_NAME} +# RUNTIME DESTINATION bin +# LIBRARY DESTINATION lib +# ARCHIVE DESTINATION lib/static +# ) +# INSTALL( +# FILES +# ${lib_HEADERS} +# DESTINATION include/${lib_DIR} +# ) + +## eof - $RCSfile$ diff --git a/lib/fpa_Instances/Filters.i b/lib/fpa_Instances/Filters.i new file mode 100644 index 0000000..28b3ac7 --- /dev/null +++ b/lib/fpa_Instances/Filters.i @@ -0,0 +1,14 @@ +f fpa_Instances/Instances.h + +t fpa/Image/RegionGrow.h +t fpa/Image/Dijkstra.h +t fpa/Image/Algorithm.h + +d #dims=2;3 +d #int=char;short;int;long +d #uint=unsigned #int +d #float=float;double +d #pixels=#int;#uint;#float + +c fpa::Image::RegionGrow< itk::Image< #pixels, #dims >, itk::Image< #uint, #dims > > +c fpa::Image::Dijkstra< itk::Image< #pixels, #dims >, itk::Image< #float, #dims > > diff --git a/lib/fpa_Instances/Instances.i b/lib/fpa_Instances/Instances.i new file mode 100644 index 0000000..372a8e7 --- /dev/null +++ b/lib/fpa_Instances/Instances.i @@ -0,0 +1,23 @@ +f cpPlugins_Instances/ImageFiltersBase.h + +t fpa/Image/MinimumSpanningTree.h +t fpa/Base/MinimumSpanningTree.h +t fpa/Base/RegionGrow.h +t fpa/Base/Dijkstra.h +t fpa/Base/Algorithm.h +t itkImportImageContainer.h +t itkImage.h + +d #dims=2;3 +d #int=char;short;int;long +d #uint=unsigned #int +d #float=float;double +d #pixels=#int;#uint;#float + +c itk::ImportImageContainer< unsigned long, fpa::Image::MinimumSpanningTreeData< #dims > > +c itk::Image< fpa::Image::MinimumSpanningTreeData< #dims >, #dims > +c fpa::Base::MinimumSpanningTree< itk::Image< fpa::Image::MinimumSpanningTreeData< #dims >, #dims >, itk::Index< #dims > > +c fpa::Image::MinimumSpanningTree< #dims > +c fpa::Base::Algorithm< itk::Index< #dims >, #pixels, #pixels, itk::Image< #pixels, #dims >, itk::Functor::IndexLexicographicCompare< #dims >, itk::ImageToImageFilter< itk::Image< #pixels, #dims >, itk::Image< #pixels, #dims > > > +c fpa::Base::Dijkstra< itk::Index< #dims >, #pixels, #float, itk::Image< #pixels, #dims >, itk::Functor::IndexLexicographicCompare< #dims >, fpa::Image::MinimumSpanningTree< #dims >, itk::ImageToImageFilter< itk::Image< #pixels, #dims >, itk::Image< #float, #dims> > > +c fpa::Base::RegionGrow< itk::Index< #dims >, #pixels, #uint, itk::Image< #pixels, #dims >, itk::Functor::IndexLexicographicCompare< #dims >, itk::ImageToImageFilter< itk::Image< #pixels, #dims >, itk::Image< #uint, #dims > > > diff --git a/lib/fpa_Instances/Observers.i b/lib/fpa_Instances/Observers.i new file mode 100644 index 0000000..a7aa67b --- /dev/null +++ b/lib/fpa_Instances/Observers.i @@ -0,0 +1,15 @@ +f fpa_Instances/Filters.h + +i vtkRenderWindow.h + +t fpa/VTK/Image2DObserver.h +t fpa/VTK/Image3DObserver.h + +d #dims=2;3 +d #int=char;short;int;long +d #uint=unsigned #int +d #float=float;double +d #pixels=#int;#uint;#float + +c @{fpa::VTK::Image2DObserver;fpa::VTK::Image3DObserver}< fpa::Image::RegionGrow< itk::Image< #pixels, #dims >, itk::Image< #uint, #dims > >, vtkRenderWindow > +c @{fpa::VTK::Image2DObserver;fpa::VTK::Image3DObserver}< fpa::Image::Dijkstra< itk::Image< #pixels, #dims >, itk::Image< #float, #dims > >, vtkRenderWindow > diff --git a/plugins/fpa/BaseImageFilter.cxx b/plugins/fpa/BaseImageFilter.cxx index cdd9f67..f10d067 100644 --- a/plugins/fpa/BaseImageFilter.cxx +++ b/plugins/fpa/BaseImageFilter.cxx @@ -1,5 +1,6 @@ #include "BaseImageFilter.h" -#include +#include +//#include // ------------------------------------------------------------------------- bool fpaPlugins::BaseImageFilter:: diff --git a/plugins/fpa/BaseImageFilter.h b/plugins/fpa/BaseImageFilter.h index 2b7e6a3..3069f49 100644 --- a/plugins/fpa/BaseImageFilter.h +++ b/plugins/fpa/BaseImageFilter.h @@ -56,7 +56,7 @@ namespace fpaPlugins protected: TMPRWidget* m_MPRViewer; vtkRenderWindowInteractor* m_SingleInteractor; - std::set< unsigned long > m_Observers; + std::set< unsigned long > m_Observers; }; } // ecapseman diff --git a/plugins/fpa/BaseImageFilter.hxx b/plugins/fpa/BaseImageFilter.hxx index 5ca2671..9db580a 100644 --- a/plugins/fpa/BaseImageFilter.hxx +++ b/plugins/fpa/BaseImageFilter.hxx @@ -1,14 +1,17 @@ #ifndef __FPAPLUGINS__BASEIMAGEFILTER__HXX__ #define __FPAPLUGINS__BASEIMAGEFILTER__HXX__ -#include -#include -#include -#include - -#include -#include +#include #include +/* TODO + #include + #include + #include + #include + + #include + #include +*/ // ------------------------------------------------------------------------- template< class _TFilter > diff --git a/plugins/fpa/CMakeLists.txt b/plugins/fpa/CMakeLists.txt index bbbd673..18f6377 100644 --- a/plugins/fpa/CMakeLists.txt +++ b/plugins/fpa/CMakeLists.txt @@ -13,15 +13,15 @@ SET( SET( filters_HEADERS_H - ${CMAKE_CURRENT_SOURCE_DIR}/MinimumSpanningTreeReader.h - ${CMAKE_CURRENT_SOURCE_DIR}/MinimumSpanningTreeWriter.h + #${CMAKE_CURRENT_SOURCE_DIR}/MinimumSpanningTreeReader.h + #${CMAKE_CURRENT_SOURCE_DIR}/MinimumSpanningTreeWriter.h ${CMAKE_CURRENT_SOURCE_DIR}/ImageRegionGrow.h ${CMAKE_CURRENT_SOURCE_DIR}/ImageDijkstra.h ${CMAKE_CURRENT_SOURCE_DIR}/ExtractPathFromMinimumSpanningTree.h ${CMAKE_CURRENT_SOURCE_DIR}/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.h - ${CMAKE_CURRENT_SOURCE_DIR}/RegionGrowThresholdFunction.h + #${CMAKE_CURRENT_SOURCE_DIR}/RegionGrowThresholdFunction.h ${CMAKE_CURRENT_SOURCE_DIR}/InvertCostFunction.h - ${CMAKE_CURRENT_SOURCE_DIR}/GradientBaseImageFunctionSource.h + #${CMAKE_CURRENT_SOURCE_DIR}/GradientBaseImageFunctionSource.h ) SET( @@ -37,24 +37,21 @@ SET( SET( filters_SOURCES_CXX - ${CMAKE_CURRENT_SOURCE_DIR}/MinimumSpanningTreeReader.cxx - ${CMAKE_CURRENT_SOURCE_DIR}/MinimumSpanningTreeWriter.cxx + #${CMAKE_CURRENT_SOURCE_DIR}/MinimumSpanningTreeReader.cxx + #${CMAKE_CURRENT_SOURCE_DIR}/MinimumSpanningTreeWriter.cxx ${CMAKE_CURRENT_SOURCE_DIR}/ImageRegionGrow.cxx ${CMAKE_CURRENT_SOURCE_DIR}/ImageDijkstra.cxx ${CMAKE_CURRENT_SOURCE_DIR}/ExtractPathFromMinimumSpanningTree.cxx ${CMAKE_CURRENT_SOURCE_DIR}/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.cxx - ${CMAKE_CURRENT_SOURCE_DIR}/RegionGrowThresholdFunction.cxx + #${CMAKE_CURRENT_SOURCE_DIR}/RegionGrowThresholdFunction.cxx ${CMAKE_CURRENT_SOURCE_DIR}/InvertCostFunction.cxx - ${CMAKE_CURRENT_SOURCE_DIR}/GradientBaseImageFunctionSource.cxx + #${CMAKE_CURRENT_SOURCE_DIR}/GradientBaseImageFunctionSource.cxx ) SET( target_LIBRARIES + ${fpa_ALL_INSTANCES} ${cpExtensions_LIBRARY} - ${cpPlugins_LIBRARY} - cpPlugins_ImageIterators - cpPlugins_Paths - ${ITK_LIBRARIES} ) ## ===================== @@ -63,8 +60,8 @@ SET( ADD_CUSTOM_COMMAND( OUTPUT ${lib_NAME}_Host.cxx - DEPENDS ${cpPlugins_HostCreator_APP} ${filters_HEADERS_H} - COMMAND ${cpPlugins_HostCreator_APP} ${lib_NAME}_Host.cxx ${filters_HEADERS_H} + DEPENDS ${cpPlugins_HostCreator} ${filters_HEADERS_H} + COMMAND ${cpPlugins_HostCreator} ${lib_NAME}_Host.cxx ${filters_HEADERS_H} ) ADD_LIBRARY( ${lib_NAME} diff --git a/plugins/fpa/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.cxx b/plugins/fpa/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.cxx index fca4620..0b1d597 100644 --- a/plugins/fpa/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.cxx +++ b/plugins/fpa/ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.cxx @@ -1,7 +1,8 @@ #include "ExtractEndPointsAndBifurcationsFromMinimumSpanningTree.h" -#include "MinimumSpanningTree.h" #include +#include +#include #include #include #include @@ -15,9 +16,9 @@ ExtractEndPointsAndBifurcationsFromMinimumSpanningTree( ) this->_AddInput( "CostsImage" ); this->_AddInput( "DistanceMap" ); this->_AddInput( "MST" ); - this->_AddOutput< cpPlugins::DataObject >( "EndPoints" ); - this->_AddOutput< cpPlugins::DataObject >( "Bifurcations" ); - this->_AddOutput< cpPlugins::DataObject >( "Collisions" ); + this->_AddOutput< cpPlugins::ImageIndexesContainer >( "EndPoints" ); + this->_AddOutput< cpPlugins::ImageIndexesContainer >( "Bifurcations" ); + this->_AddOutput< cpPlugins::ImageIndexesContainer >( "Collisions" ); this->m_Parameters.ConfigureAsBool( "SquaredDistanceMap" ); this->m_Parameters.SetBool( "SquaredDistanceMap", false ); diff --git a/plugins/fpa/ExtractPathFromMinimumSpanningTree.cxx b/plugins/fpa/ExtractPathFromMinimumSpanningTree.cxx index bde69fc..d914d6a 100644 --- a/plugins/fpa/ExtractPathFromMinimumSpanningTree.cxx +++ b/plugins/fpa/ExtractPathFromMinimumSpanningTree.cxx @@ -1,11 +1,11 @@ #include "ExtractPathFromMinimumSpanningTree.h" -#include "MinimumSpanningTree.h" +#include #include #include #include #include -#include +#include #include #include @@ -16,7 +16,7 @@ ExtractPathFromMinimumSpanningTree( ) { this->_AddInput( "MST" ); this->_AddInput( "Seeds" ); - this->_AddOutput< cpPlugins::DataObject >( "Output" ); + this->_AddOutput< cpPlugins::Path >( "Output" ); this->m_Parameters.ConfigureAsUint( "Vertex0" ); this->m_Parameters.ConfigureAsUint( "Vertex1" ); diff --git a/plugins/fpa/ImageDijkstra.cxx b/plugins/fpa/ImageDijkstra.cxx index cd34a9c..b5b3a62 100644 --- a/plugins/fpa/ImageDijkstra.cxx +++ b/plugins/fpa/ImageDijkstra.cxx @@ -2,13 +2,15 @@ #include "MinimumSpanningTree.h" #include -#include -#include -#include +#include +#include + #include +#include #include -#include -#include +#include +#include +#include // ------------------------------------------------------------------------- fpaPlugins::ImageDijkstra:: diff --git a/plugins/fpa/ImageRegionGrow.cxx b/plugins/fpa/ImageRegionGrow.cxx index a988c63..27d5eca 100644 --- a/plugins/fpa/ImageRegionGrow.cxx +++ b/plugins/fpa/ImageRegionGrow.cxx @@ -1,12 +1,15 @@ #include "ImageRegionGrow.h" #include -#include -#include -#include +#include +#include + #include +#include #include -#include +#include +#include +#include // ------------------------------------------------------------------------- fpaPlugins::ImageRegionGrow:: diff --git a/plugins/fpa/MinimumSpanningTree.cxx b/plugins/fpa/MinimumSpanningTree.cxx index 4ad07f3..53bcdaf 100644 --- a/plugins/fpa/MinimumSpanningTree.cxx +++ b/plugins/fpa/MinimumSpanningTree.cxx @@ -1,4 +1,5 @@ #include +#include // ------------------------------------------------------------------------- void fpaPlugins::MinimumSpanningTree:: @@ -53,24 +54,4 @@ _SetITK( itk::LightObject* o ) } // fi } -// ------------------------------------------------------------------------- -// Explicit instances -// ------------------------------------------------------------------------- - -#include -#include -#include -#include -#include -#include - -#define fpa_Explicit_MST( D ) \ - template class fpaPlugins_EXPORT fpa::Base::MinimumSpanningTree< itk::Image< fpa::Image::MinimumSpanningTreeData< D >, D >, itk::Index< D > >; \ - template class fpaPlugins_EXPORT fpa::Image::MinimumSpanningTree< D >; \ - template class fpaPlugins_EXPORT itk::ImageConstIteratorWithIndex< fpa::Image::MinimumSpanningTree< D > >; \ - template class fpaPlugins_EXPORT itk::ImageRegionConstIteratorWithIndex< fpa::Image::MinimumSpanningTree< D > > - -fpa_Explicit_MST( 2 ); -fpa_Explicit_MST( 3 ); - // eof - $RCSfile$ diff --git a/plugins/fpa/MinimumSpanningTree.h b/plugins/fpa/MinimumSpanningTree.h index 26e0262..2904600 100644 --- a/plugins/fpa/MinimumSpanningTree.h +++ b/plugins/fpa/MinimumSpanningTree.h @@ -3,7 +3,6 @@ #include #include -#include // ------------------------------------------------------------------------- namespace fpaPlugins -- 2.47.1