X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FcpInstances%2FDataObjects%2FBoundingBox.h;fp=lib%2FcpInstances%2FDataObjects%2FBoundingBox.h;h=0000000000000000000000000000000000000000;hb=2e142df11d6f312a2a2b5097b8da73571ed523e8;hp=dfe130030c401027739dd62c08a4aeb32d24be3a;hpb=61b3659afe961ed248f30e26f9ca8f28fcfafddc;p=cpPlugins.git diff --git a/lib/cpInstances/DataObjects/BoundingBox.h b/lib/cpInstances/DataObjects/BoundingBox.h deleted file mode 100644 index dfe1300..0000000 --- a/lib/cpInstances/DataObjects/BoundingBox.h +++ /dev/null @@ -1,107 +0,0 @@ -#ifndef __cpInstances__BoundingBox__h__ -#define __cpInstances__BoundingBox__h__ - -#define ITK_MANUAL_INSTANTIATION -#include -#include -#include -#include -#include - -namespace cpInstances -{ - namespace DataObjects - { - /** - */ - class cpPluginsDataObjects_EXPORT BoundingBox - : public cpPlugins::Pipeline::DataObject - { - public: - typedef BoundingBox Self; - typedef cpPlugins::Pipeline::DataObject Superclass; - typedef itk::SmartPointer< Self > Pointer; - typedef itk::SmartPointer< const Self > ConstPointer; - - public: - itkNewMacro( Self ); - itkTypeMacro( BoundingBox, DataObject ); - cpPlugins_Id_Macro( BoundingBox, Object ); - cpPlugins_Compatibility_Macro; - - public: - void SetDataObject( DataObject* o ); - - void Copy( Self* other ); - void Blend( Self* other ); - - template< class _TPoint > - inline void SetMinimum( const _TPoint& p ) - { - this->_SetPoint( 0, p ); - } - - template< class _TPoint > - inline void SetMaximum( const _TPoint& p ) - { - this->_SetPoint( 1, p ); - } - - template< class _TPoint > - inline _TPoint GetMinimum( ) const - { - return( this->_GetPoint< _TPoint >( 0 ) ); - } - - template< class _TPoint > - inline _TPoint GetMaximum( ) const - { - return( this->_GetPoint< _TPoint >( 1 ) ); - } - - protected: - BoundingBox( ); - virtual ~BoundingBox( ); - - void _UpdateVTK( ); - - template< class _TPoint > - inline void _SetPoint( unsigned int m, const _TPoint& p ) - { - this->m_Points[ m ].clear( ); - for( unsigned int d = 0; d < _TPoint::PointDimension; ++d ) - this->m_Points[ m ].push_back( double( p[ d ] ) ); - this->_UpdateVTK( ); - this->Modified( ); - } - - template< class _TPoint > - inline _TPoint _GetPoint( unsigned int m ) const - { - unsigned int dim = this->m_Points[ m ].size( ); - dim = - ( _TPoint::PointDimension < dim )? _TPoint::PointDimension: dim; - _TPoint p; - p.Fill( 0 ); - for( unsigned int d = 0; d < dim; ++d ) - p[ d ] = this->m_Points[ m ][ d ]; - return( p ); - } - - private: - // Purposely not implemented - BoundingBox( const Self& ); - Self& operator=( const Self& ); - - protected: - std::vector< double > m_Points[ 2 ]; - vtkSmartPointer< vtkOutlineSource > m_Outline; - }; - - } // ecapseman - -} // ecapseman - -#endif // __cpInstances__BoundingBox__h__ - -// eof - $RCSfile$