X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FcpExtensions%2FDataStructures%2FPolyLineParametricPath.h;h=3358d0fc4c13d130b6bb34b6ce23068c9eb8c2d3;hb=211cd32b53b9739923f6c5135a704ce1852deca1;hp=e8046eac90e76207393d1dcd66ed2e837d6761d0;hpb=1f5c3516bf4240bcdd91979ac303298ef1f75fc3;p=cpPlugins.git diff --git a/lib/cpExtensions/DataStructures/PolyLineParametricPath.h b/lib/cpExtensions/DataStructures/PolyLineParametricPath.h index e8046ea..3358d0f 100644 --- a/lib/cpExtensions/DataStructures/PolyLineParametricPath.h +++ b/lib/cpExtensions/DataStructures/PolyLineParametricPath.h @@ -3,6 +3,7 @@ #include #include +#include namespace cpExtensions { @@ -26,6 +27,9 @@ namespace cpExtensions typedef typename TImageBase::DirectionType TDirection; typedef typename Superclass::ContinuousIndexType TContinuousIndex; + typedef typename TPoint::VectorType TVector; + typedef cpExtensions::Algorithms::BezierCurveFunction< TVector > TBezier; + public: itkNewMacro( Self ); itkTypeMacro( PolyLineParametricPath, itk::PolyLineParametricPath ); @@ -38,9 +42,11 @@ namespace cpExtensions itkSetMacro( Origin, TPoint ); public: + void AddVertex( const TContinuousIndex& vertex ); unsigned long GetSize( ) const; TContinuousIndex GetVertex( unsigned long i ) const; TPoint GetPoint( unsigned long i ) const; + TPoint GetSmoothPoint( double u ) const; virtual void SetSpacing( const TSpacing& spac ); virtual void SetSpacing( const double spac[ _VDim ] ); @@ -69,6 +75,8 @@ namespace cpExtensions Self& operator=( const Self& other ); protected: + typename TBezier::Pointer m_Bezier; + TSpacing m_Spacing; TPoint m_Origin; TDirection m_Direction;