Skip to content

Commit

Permalink
eigen serialization from pinocchio 2.6.0, fix loco-3d#24
Browse files Browse the repository at this point in the history
ref. loco-3d/ndcurves#63

Co-authored-by: pFernbach <[email protected]>
  • Loading branch information
nim65s and pFernbach committed Jan 25, 2022
1 parent 036b902 commit 38277d8
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions include/multicontact-api/serialization/eigen-matrix.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,17 @@
#ifndef EIGEN_BOOST_SERIALIZATION
#define EIGEN_BOOST_SERIALIZATION

#ifdef CURVES_WITH_PINOCCHIO_SUPPORT
#include <pinocchio/config.hpp>
#if PINOCCHIO_VERSION_AT_LEAST(2, 6, 0)
#define CURVES_WITH_PINOCCHIO_260
#endif
#endif

#ifdef CURVES_WITH_PINOCCHIO_260
#include <pinocchio/serialization/eigen.hpp>
#else

#include <Eigen/Dense>
#include <boost/serialization/split_free.hpp>
#include <boost/serialization/vector.hpp>
Expand Down Expand Up @@ -69,4 +80,8 @@ void serialize(Archive& ar, Eigen::Matrix<_Scalar, _Rows, _Cols, _Options, _MaxR
} // namespace serialization
} // namespace boost

#endif

#undef CURVES_WITH_PINOCCHIO_260

#endif // ifndef __multicontact_api_serialization_eigen_matrix_hpp__

0 comments on commit 38277d8

Please sign in to comment.