DGtal  1.0.0
Public Types | Public Member Functions | Private Attributes
DGtal::ParametricShapeTangentFunctor< TParametricShape > Class Template Reference

Aim: implements a functor that computes the tangent vector at a given point of a parametric shape. More...

#include <DGtal/geometry/curves/estimation/ParametricShapeTangentFunctor.h>

Public Types

typedef TParametricShape ParametricShape
 Type of parametric shape. More...
 
typedef TParametricShape::RealPoint RealPoint
 Type of points. More...
 
typedef TParametricShape::RealPoint Quantity
 Type of the functor output. More...
 

Public Member Functions

 ParametricShapeTangentFunctor ()
 
 ParametricShapeTangentFunctor (ParametricShape *aShape)
 
 ~ParametricShapeTangentFunctor ()
 
ParametricShapeTangentFunctoroperator= (const ParametricShapeTangentFunctor &other)
 
Quantity operator() (const RealPoint &aPoint)
 

Private Attributes

ParametricShapemyShape
 Copy of the implicit shape. More...
 

Detailed Description

template<typename TParametricShape>
class DGtal::ParametricShapeTangentFunctor< TParametricShape >

Aim: implements a functor that computes the tangent vector at a given point of a parametric shape.

Description of template class 'ParametricShapeTangentFunctor'

Template Parameters
TParametricShapea model of parametric shape.

Definition at line 63 of file ParametricShapeTangentFunctor.h.

Member Typedef Documentation

◆ ParametricShape

template<typename TParametricShape >
typedef TParametricShape DGtal::ParametricShapeTangentFunctor< TParametricShape >::ParametricShape

Type of parametric shape.

Definition at line 70 of file ParametricShapeTangentFunctor.h.

◆ Quantity

template<typename TParametricShape >
typedef TParametricShape::RealPoint DGtal::ParametricShapeTangentFunctor< TParametricShape >::Quantity

Type of the functor output.

Definition at line 76 of file ParametricShapeTangentFunctor.h.

◆ RealPoint

template<typename TParametricShape >
typedef TParametricShape::RealPoint DGtal::ParametricShapeTangentFunctor< TParametricShape >::RealPoint

Type of points.

Definition at line 73 of file ParametricShapeTangentFunctor.h.

Constructor & Destructor Documentation

◆ ParametricShapeTangentFunctor() [1/2]

template<typename TParametricShape >
DGtal::ParametricShapeTangentFunctor< TParametricShape >::ParametricShapeTangentFunctor ( )
inline

Constructor.

Definition at line 81 of file ParametricShapeTangentFunctor.h.

81 {}

◆ ParametricShapeTangentFunctor() [2/2]

template<typename TParametricShape >
DGtal::ParametricShapeTangentFunctor< TParametricShape >::ParametricShapeTangentFunctor ( ParametricShape aShape)
inline

Constructor..

Parameters
aShapethe input shape.

Definition at line 89 of file ParametricShapeTangentFunctor.h.

89 : myShape(aShape) {};
ParametricShape * myShape
Copy of the implicit shape.

◆ ~ParametricShapeTangentFunctor()

template<typename TParametricShape >
DGtal::ParametricShapeTangentFunctor< TParametricShape >::~ParametricShapeTangentFunctor ( )
inline

Destructor.

Definition at line 95 of file ParametricShapeTangentFunctor.h.

95 {}

Member Function Documentation

◆ operator()()

template<typename TParametricShape >
Quantity DGtal::ParametricShapeTangentFunctor< TParametricShape >::operator() ( const RealPoint aPoint)
inline

Compute the tangent at [aPoint]

Parameters
aPointthe point at which the tangent is computed.
Returns
the tangent at [aPoint].

Definition at line 119 of file ParametricShapeTangentFunctor.h.

120  {
121  ASSERT(myShape);
122 
123  double t = myShape->parameter( aPoint );
124  return myShape->tangent( t );
125  }
const Point aPoint(3, 4)
ParametricShape * myShape
Copy of the implicit shape.

References aPoint(), and DGtal::ParametricShapeTangentFunctor< TParametricShape >::myShape.

◆ operator=()

template<typename TParametricShape >
ParametricShapeTangentFunctor& DGtal::ParametricShapeTangentFunctor< TParametricShape >::operator= ( const ParametricShapeTangentFunctor< TParametricShape > &  other)
inline

Assignment.

Parameters
otherthe object to copy.
Returns
a reference on 'this'. Forbidden by default.

Definition at line 106 of file ParametricShapeTangentFunctor.h.

107  {
108  myShape = other.myShape;
109  return *this;
110  }
ParametricShape * myShape
Copy of the implicit shape.

References DGtal::ParametricShapeTangentFunctor< TParametricShape >::myShape.

Field Documentation

◆ myShape

template<typename TParametricShape >
ParametricShape* DGtal::ParametricShapeTangentFunctor< TParametricShape >::myShape
private

The documentation for this class was generated from the following file: