Commit 7d23ecc7 authored by JasonChmn's avatar JasonChmn

change namespace spline to curve in include folder, rename folder spline to...

change namespace spline to curve in include folder, rename folder spline to curve, change in the CmakeList.txt
parent dc7ad399
......@@ -33,7 +33,7 @@ IF(BUILD_PYTHON_INTERFACE)
ENDIF(BUILD_PYTHON_INTERFACE)
ADD_SUBDIRECTORY(include/hpp/spline)
ADD_SUBDIRECTORY(include/hpp/curve)
ADD_SUBDIRECTORY(tests)
SETUP_HPP_PROJECT_FINALIZE()
......@@ -14,7 +14,7 @@ SET(${PROJECT_NAME}_HEADERS
INSTALL(FILES
${${PROJECT_NAME}_HEADERS}
DESTINATION include/hpp/spline
DESTINATION include/hpp/curve
)
ADD_SUBDIRECTORY(helpers)
......@@ -20,8 +20,7 @@
#include <vector>
#include <utility>
namespace spline{
namespace curve{
//REF: boulic et al An inverse kinematics architecture enforcing an arbitrary number of strict priority levels
template<typename _Matrix_Type_>
......@@ -41,6 +40,6 @@ void PseudoInverse(_Matrix_Type_& pinvmat)
pinvmat = (svd.matrixV()*m_sigma_inv*svd.matrixU().transpose());
}
} // namespace spline
} // namespace curve
#endif //_SPLINEMATH
......@@ -18,7 +18,7 @@
#include <vector>
#include <stdexcept>
namespace spline
namespace curve
{
///
/// \brief Computes factorial of a number
......@@ -74,6 +74,6 @@ std::vector<Bern<Numeric> > makeBernstein(const unsigned int n)
res.push_back(Bern<Numeric>(n, i));
return res;
}
} // namespace spline
} // namespace curve
#endif //_CLASS_BERNSTEIN
......@@ -21,7 +21,7 @@
#include <iostream>
namespace spline
namespace curve
{
/// \class BezierCurve
/// \brief Represents a Bezier curve of arbitrary dimension and order.
......@@ -51,7 +51,7 @@ struct bezier_curve : public curve_abc<Time, Numeric, Dim, Safe, Point>
, mult_T_(1.)
, size_(std::distance(PointsBegin, PointsEnd))
, degree_(size_-1)
, bernstein_(spline::makeBernstein<num_t>((unsigned int)degree_))
, bernstein_(curve::makeBernstein<num_t>((unsigned int)degree_))
{
assert(bernstein_.size() == size_);
In it(PointsBegin);
......@@ -70,7 +70,7 @@ struct bezier_curve : public curve_abc<Time, Numeric, Dim, Safe, Point>
, mult_T_(1.)
, size_(std::distance(PointsBegin, PointsEnd))
, degree_(size_-1)
, bernstein_(spline::makeBernstein<num_t>((unsigned int)degree_))
, bernstein_(curve::makeBernstein<num_t>((unsigned int)degree_))
{
assert(bernstein_.size() == size_);
In it(PointsBegin);
......@@ -91,7 +91,7 @@ struct bezier_curve : public curve_abc<Time, Numeric, Dim, Safe, Point>
, mult_T_(mult_T)
, size_(std::distance(PointsBegin, PointsEnd))
, degree_(size_-1)
, bernstein_(spline::makeBernstein<num_t>((unsigned int)degree_))
, bernstein_(curve::makeBernstein<num_t>((unsigned int)degree_))
{
assert(bernstein_.size() == size_);
In it(PointsBegin);
......@@ -113,7 +113,7 @@ struct bezier_curve : public curve_abc<Time, Numeric, Dim, Safe, Point>
, mult_T_(1.)
, size_(std::distance(PointsBegin, PointsEnd)+4)
, degree_(size_-1)
, bernstein_(spline::makeBernstein<num_t>((unsigned int)degree_))
, bernstein_(curve::makeBernstein<num_t>((unsigned int)degree_))
{
if(Safe && (size_<1 || T_ <= 0.))
throw std::out_of_range("can't create bezier min bound is higher than max bound");
......
......@@ -21,7 +21,7 @@
#include <iostream>
namespace spline
namespace curve
{
/// \brief Provides methods for converting a curve from a bernstein representation
/// to a polynom representation
......
......@@ -20,7 +20,7 @@
#include <stdexcept>
namespace spline
namespace curve
{
/// \brief Creates coefficient vector of a cubic spline defined on the interval
/// [tBegin, tEnd]. It follows the equation
......
......@@ -16,7 +16,7 @@
#include <functional>
namespace spline
namespace curve
{
/// \struct curve_abc
/// \brief Represents a curve of dimension Dim
......
......@@ -17,7 +17,7 @@
#include <functional>
#include <vector>
namespace spline
namespace curve
{
template <typename Point>
struct curve_constraints
......
......@@ -29,7 +29,7 @@
#include <functional>
#include <vector>
namespace spline
namespace curve
{
/// \class ExactCubic
/// \brief Represents a set of cubic splines defining a continuous function
......
......@@ -5,5 +5,5 @@ SET(${PROJECT_NAME}_HELPERS_HEADERS
INSTALL(FILES
${${PROJECT_NAME}_HELPERS_HEADERS}
DESTINATION include/hpp/spline/helpers
DESTINATION include/hpp/curve/helpers
)
......@@ -20,9 +20,9 @@
#ifndef _CLASS_EFFECTORSPLINE
#define _CLASS_EFFECTORSPLINE
#include "hpp/spline/spline_deriv_constraint.h"
#include "hpp/curve/spline_deriv_constraint.h"
namespace spline
namespace curve
{
namespace helpers
{
......
......@@ -20,11 +20,11 @@
#ifndef _CLASS_EFFECTOR_SPLINE_ROTATION
#define _CLASS_EFFECTOR_SPLINE_ROTATION
#include "hpp/spline/helpers/effector_spline.h"
#include "hpp/spline/curve_abc.h"
#include "hpp/curve/helpers/effector_spline.h"
#include "hpp/curve/curve_abc.h"
#include <Eigen/Geometry>
namespace spline
namespace curve
{
namespace helpers
{
......@@ -252,5 +252,5 @@ class effector_spline_rotation
};
} // namespace helpers
} // namespace spline
} // namespace curve
#endif //_CLASS_EFFECTOR_SPLINE_ROTATION
......@@ -12,15 +12,15 @@
#ifndef _CLASS_SPLINEOPTIMIZER
#define _CLASS_SPLINEOPTIMIZER
#include "spline/MathDefs.h"
#include "spline/exact_cubic.h"
#include "curve/MathDefs.h"
#include "curve/exact_cubic.h"
#include "mosek/mosek.h"
#include <Eigen/SparseCore>
#include <utility>
namespace spline
namespace curve
{
/// \class SplineOptimizer
/// \brief Mosek connection to produce optimized splines
......@@ -516,5 +516,5 @@ inline exact_cubic<Time, Numeric, Dim, Safe, Point>*
return res;
}
} // namespace spline
} // namespace curve
#endif //_CLASS_SPLINEOPTIMIZER
......@@ -23,7 +23,7 @@
#include <functional>
#include <stdexcept>
namespace spline
namespace curve
{
/// \class polynom
/// \brief Represents a polynomf arbitrary order defined on the interval
......
......@@ -20,7 +20,7 @@
#include <stdexcept>
namespace spline
namespace curve
{
/// \brief Creates coefficient vector of a quintic spline defined on the interval
/// [tBegin, tEnd]. It follows the equation
......
......@@ -28,7 +28,7 @@
#include <functional>
#include <vector>
namespace spline
namespace curve
{
/// \class spline_deriv_constraint.
/// \brief Represents a set of cubic splines defining a continuous function
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment