X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FcpPlugins%2FInterface%2FPointList.hxx;h=651e4cdcce17123ed446ff85af17c6399294c0b9;hb=b6c7e73ebcce23619daced67f85d9e1364b33f30;hp=95e9e1fa5a89db2c345fa01b9bf389427cee702e;hpb=8ad95abe02b030bef4c1da5e827a5309c560aea2;p=cpPlugins.git diff --git a/lib/cpPlugins/Interface/PointList.hxx b/lib/cpPlugins/Interface/PointList.hxx index 95e9e1f..651e4cd 100644 --- a/lib/cpPlugins/Interface/PointList.hxx +++ b/lib/cpPlugins/Interface/PointList.hxx @@ -1,52 +1,7 @@ #ifndef __CPPLUGINS__INTERFACE__POINTLIST__HXX__ #define __CPPLUGINS__INTERFACE__POINTLIST__HXX__ -#include -#include -#include - -// ------------------------------------------------------------------------- -template< class P > -void cpPlugins::Interface::PointList:: -AddPoint( const P& p ) -{ - typedef itk::SimpleDataObjectDecorator< std::vector< P > > _T; - - _T* container = NULL; - if( this->m_NumberOfPoints == 0 ) - { - typename _T::Pointer obj = _T::New( ); - container = obj.GetPointer( ); - this->m_ITKObject = container; - } - else - container = dynamic_cast< _T* >( this->m_ITKObject.GetPointer( ) ); - - if( container != NULL ) - { - container->Get( ).push_back( p ); - this->m_NumberOfPoints += 1; - - } // fi -} - -// ------------------------------------------------------------------------- -template< class P > -P cpPlugins::Interface::PointList:: -GetPoint( const unsigned long& i ) const -{ - typedef itk::SimpleDataObjectDecorator< std::vector< P > > _T; - - P ret; - if( i < this->m_NumberOfPoints ) - { - _T* container = dynamic_cast< _T* >( this->m_ITKObject.GetPointer( ) ); - if( container != NULL ) - ret = container->Get( )[ i ]; - - } // fi - return( ret ); -} +// TODO: erase this file #endif // __CPPLUGINS__INTERFACE__POINTLIST__HXX__