Curve_ABC.h 1.29 KB
Newer Older
1
/**
2
3
* \file curve_abc.h
* \brief interface for a Curve of arbitrary dimension.
4
5
6
7
8
9
10
11
* \author Steve T.
* \version 0.1
* \date 06/17/2013
*
* Interface for a curve
*/


12
13
#ifndef _STRUCT_CURVE_ABC
#define _STRUCT_CURVE_ABC
14
15
16
17

#include "Exports.h"
#include "MathDefs.h"

18
#include <functional>
19
20
21

namespace spline
{
22
23
24
25
26
27
28
29
30
31
/// \struct curve_abc
/// \brief Represents a curve of dimension Dim
/// is Safe is false, no verification is made on the evaluation of the curve.
template<typename Time= double, typename Numeric=Time, int Dim=3, bool Safe=false
, typename Point= Eigen::Matrix<Numeric, Dim, 1> >
struct  curve_abc : std::unary_function<Time, Point>
{
	typedef Point 	point_t;
	typedef Time 	time_t;

32
33
/* Constructors - destructors */
	public:
34
35
	///\brief Constructor
	SPLINE_API curve_abc(){};
36

37
38
	///\brief Destructor
	SPLINE_API ~curve_abc(){};
39
40
41
42
43
44
/* Constructors - destructors */

/*Operations*/
	public:
	///  \brief Evaluation of the cubic spline at time t.
	///  \param t : the time when to evaluate the spine
45
46
	///  \param return : the value x(t)
	SPLINE_API virtual point_t operator()(time_t t) const = 0;
47
48
49
/*Operations*/

/*Helpers*/
50
51
	SPLINE_API virtual time_t MinBound() const = 0;
	SPLINE_API virtual time_t MaxBound() const = 0;
52
53
54
55
/*Helpers*/

	};
}
56
#endif //_STRUCT_CURVE_ABC
57