X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FcpExtensions%2FAlgorithms%2FBezierCurveFunction.h;fp=lib%2FcpExtensions%2FAlgorithms%2FBezierCurveFunction.h;h=0000000000000000000000000000000000000000;hb=2e142df11d6f312a2a2b5097b8da73571ed523e8;hp=65c3af8be41a7537554423efe6bb878075422c6e;hpb=61b3659afe961ed248f30e26f9ca8f28fcfafddc;p=cpPlugins.git diff --git a/lib/cpExtensions/Algorithms/BezierCurveFunction.h b/lib/cpExtensions/Algorithms/BezierCurveFunction.h deleted file mode 100644 index 65c3af8..0000000 --- a/lib/cpExtensions/Algorithms/BezierCurveFunction.h +++ /dev/null @@ -1,77 +0,0 @@ -// ------------------------------------------------------------------------- -// @author Leonardo Florez-Valencia (florez-l@javeriana.edu.co) -// ------------------------------------------------------------------------- - -#ifndef __CPEXTENSIONS__ALGORITHMS__BEZIERCURVEFUNCTION__H__ -#define __CPEXTENSIONS__ALGORITHMS__BEZIERCURVEFUNCTION__H__ - -#include -#include -#include -#include - -namespace cpExtensions -{ - namespace Algorithms - { - /** - * Uses the De Casteljau's algorithm. - */ - template< class V > - class BezierCurveFunction - : public itk::FunctionBase< typename V::ValueType, V > - { - public: - typedef BezierCurveFunction Self; - typedef itk::FunctionBase< typename V::ValueType, V > Superclass; - typedef itk::SmartPointer< Self > Pointer; - typedef itk::SmartPointer< const Self > ConstPointer; - - typedef V TVector; - typedef typename V::ValueType TScalar; - - typedef - itk::Matrix< TScalar, TVector::Dimension, TVector::Dimension > - TFrame; - typedef std::vector< TVector > TVectorsContainer; - - public: - itkNewMacro( Self ); - itkTypeMacro( BezierCurveFunction, itkFunctionBase ); - - public: - virtual void AddPoint( const TVector& v ); - virtual unsigned int GetNumberOfPoints( ) const; - - virtual TVector Evaluate( const TScalar& u ) const cpExtensions_OVERRIDE; - virtual TFrame EvaluateFrenetFrame( const TScalar& u ) const; - virtual TScalar EvaluateLength( ) const; - - protected: - BezierCurveFunction( ); - virtual ~BezierCurveFunction( ) { } - - void _UpdateDerivative( ) const; - - private: - // Purposely not implemented - BezierCurveFunction( const Self& other ); - Self& operator=( const Self& other ); - - protected: - TVectorsContainer m_Vectors; - mutable Pointer m_Derivative; - mutable bool m_DerivativeUpdated; - }; - - } // ecapseman - -} // ecapseman - -#ifndef ITK_MANUAL_INSTANTIATION -# include -#endif // ITK_MANUAL_INSTANTIATION - -#endif // __CPEXTENSIONS__ALGORITHMS__BEZIERCURVEFUNCTION__H__ - -// eof - $RCSfile$