Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Stack Of Tasks
pinocchio
Commits
8ed8a4cb
Commit
8ed8a4cb
authored
Jan 10, 2018
by
jcarpent
Browse files
[All] Replace definition EIGEN3_{FUTURE,BETA} by internal Eigen macro
parent
be395a5c
Changes
5
Hide whitespace changes
Inline
Side-by-side
CMakeLists.txt
View file @
8ed8a4cb
...
...
@@ -81,22 +81,6 @@ ADD_OPTIONAL_DEPENDENCY("metapod >= 1.0.7")
ADD_OPTIONAL_DEPENDENCY
(
"urdfdom >= 0.2.0"
)
ADD_OPTIONAL_DEPENDENCY
(
"hpp-fcl >= 0.5.1"
)
# Spetcial care of Eigen3 greater than 3.2.10
IF
(
EIGEN3_FOUND
)
IF
(
${
EIGEN3_VERSION
}
VERSION_GREATER
"3.2.10"
)
ADD_DEFINITIONS
(
-DEIGEN3_FUTURE
)
SET
(
EIGEN3_FUTURE TRUE
)
PKG_CONFIG_APPEND_CFLAGS
(
"-DEIGEN3_FUTURE"
)
IF
(
${
EIGEN3_VERSION
}
VERSION_LESS
"3.3.0"
)
ADD_DEFINITIONS
(
-DEIGEN3_BETA_3_2_9x
)
SET
(
EIGEN3_FUTURE TRUE
)
PKG_CONFIG_APPEND_CFLAGS
(
"-DEIGEN3_BETA_3_2_9x"
)
ENDIF
(
${
EIGEN3_VERSION
}
VERSION_LESS
"3.3.0"
)
ELSE
(
${
EIGEN3_VERSION
}
VERSION_GREATER
"3.2.10"
)
SET
(
EIGEN3_FUTURE FALSE
)
ENDIF
(
${
EIGEN3_VERSION
}
VERSION_GREATER
"3.2.10"
)
ENDIF
(
EIGEN3_FOUND
)
# Special care of urdfdom version
IF
(
URDFDOM_FOUND
)
IF
(
${
URDFDOM_VERSION
}
VERSION_LESS
"0.3.0"
)
...
...
src/macros.hpp
View file @
8ed8a4cb
...
...
@@ -44,7 +44,7 @@ Eigen::ScalarBinaryOpTraits< typename Eigen::internal::traits< D1 >::Scalar, typ
Eigen::internal::scalar_product_traits<typename Eigen::internal::traits< D1 >::Scalar,typename Eigen::internal::traits< D2 >::Scalar>::ReturnType
#endif
#if
def
EIGEN
3_BETA_3_2_9x
#if EIGEN
_VERSION_AT_LEAST(3,2,90) && !EIGEN_VERSION_AT_LEAST(3,3,0)
namespace
se3
{
namespace
internal
...
...
src/multibody/joint/joint-prismatic-unaligned.hpp
View file @
8ed8a4cb
...
...
@@ -165,7 +165,7 @@ namespace se3
/* [CRBA] MatrixBase operator* (Constraint::Transpose S, ForceSet::Block) */
template
<
typename
D
>
friend
#if
def
EIGEN
3_FUTURE
#if EIGEN
_VERSION_AT_LEAST(3,2,90)
const
Eigen
::
Product
<
Eigen
::
Transpose
<
const
Vector3
>
,
typename
Eigen
::
MatrixBase
<
const
D
>::
template
NRowsBlockXpr
<
3
>
::
Type
...
...
@@ -235,7 +235,7 @@ namespace se3
/* [ABA] Y*S operator (Inertia Y,Constraint S) */
inline
#if
def
EIGEN
3_FUTURE
#if EIGEN
_VERSION_AT_LEAST(3,2,90)
const
Eigen
::
Product
<
Eigen
::
Block
<
const
Inertia
::
Matrix6
,
6
,
3
>
,
ConstraintPrismaticUnaligned
::
Vector3
,
...
...
src/multibody/joint/joint-revolute-unaligned.hpp
View file @
8ed8a4cb
...
...
@@ -167,7 +167,7 @@ namespace se3
/* [CRBA] MatrixBase operator* (Constraint::Transpose S, ForceSet::Block) */
template
<
typename
D
>
friend
#if
def
EIGEN
3_FUTURE
#if EIGEN
_VERSION_AT_LEAST(3,2,90)
const
Eigen
::
Product
<
Eigen
::
Transpose
<
const
Vector3
>
,
typename
Eigen
::
MatrixBase
<
const
D
>::
template
NRowsBlockXpr
<
3
>
::
Type
...
...
@@ -243,7 +243,7 @@ namespace se3
/* [ABA] Y*S operator (Inertia Y,Constraint S) */
// inline Eigen::Matrix<double,6,1>
inline
#if
def
EIGEN
3_FUTURE
#if EIGEN
_VERSION_AT_LEAST(3,2,90)
const
Eigen
::
Product
<
Eigen
::
Block
<
const
Inertia
::
Matrix6
,
6
,
3
>
,
ConstraintRevoluteUnaligned
::
Vector3
...
...
src/multibody/joint/joint-spherical-ZYX.hpp
View file @
8ed8a4cb
...
...
@@ -160,7 +160,7 @@ namespace se3
ConstraintTranspose
(
const
ConstraintRotationalSubspaceTpl
&
ref
)
:
ref
(
ref
)
{}
template
<
typename
Derived
>
#if
def
EIGEN
3_FUTURE
#if EIGEN
_VERSION_AT_LEAST(3,2,90)
const
typename
Eigen
::
Product
<
Eigen
::
Transpose
<
const
Matrix3
>
,
Eigen
::
Block
<
const
typename
ForceDense
<
Derived
>::
Vector6
,
3
,
1
>
...
...
@@ -179,7 +179,7 @@ namespace se3
/* [CRBA] MatrixBase operator* (Constraint::Transpose S, ForceSet::Block) */
template
<
typename
D
>
#if
def
EIGEN
3_FUTURE
#if EIGEN
_VERSION_AT_LEAST(3,2,90)
const
typename
Eigen
::
Product
<
typename
Eigen
::
Transpose
<
const
Matrix3
>
,
typename
Eigen
::
MatrixBase
<
const
D
>::
template
NRowsBlockXpr
<
3
>
::
Type
...
...
@@ -298,24 +298,24 @@ namespace se3
}
/* [ABA] Y*S operator (Inertia Y,Constraint S) */
//
template <typename _Scalar, int _Options
>
// inline Eigen::Matrix<
_Scalar,
6,3,
_Options>
//
#if
def
EIGEN
3_FUTURE
//
const typename Eigen::Product<
//
const Eigen::
template
Block<const
typename InertiaTpl<_Scalar,_Options>
::Matrix6,6,3>,
//
const typename JointSphericalZYXTpl<_Scalar,_Options>::ConstraintRotationalSubspace::Matrix3
//
>
//
#else
//
const typename Eigen::ProductReturnType<
//
const Eigen::
template
Block<const
typename InertiaTpl<_Scalar,_Options>
::Matrix6,6,3>,
//
const typename JointSphericalZYXTpl<_Scalar,_Options>::ConstraintRotationalSubspace::Matrix3
//
>::Type
//
#endif
//
operator*(const typename InertiaTpl<_Scalar,_Options>::Matrix6 & Y,
//
const typename JointSphericalZYXTpl<_Scalar,_Options>::ConstraintRotationalSubspace & S)
//
{
//
return Y.template middleCols<3>(Inertia::ANGULAR) * S.S_minimal;
//
}
//
inline Eigen::Matrix<double,6,3
>
template
<
typename
_Scalar
,
int
_Options
>
#if EIGEN
_VERSION_AT_LEAST(3,2,90)
const
typename
Eigen
::
Product
<
const
Eigen
::
Block
<
const
Inertia
::
Matrix6
,
6
,
3
>
,
const
typename
JointSphericalZYXTpl
<
_Scalar
,
_Options
>::
ConstraintRotationalSubspace
::
Matrix3
>
#else
const
typename
Eigen
::
ProductReturnType
<
const
Eigen
::
Block
<
const
Inertia
::
Matrix6
,
6
,
3
>
,
const
typename
JointSphericalZYXTpl
<
_Scalar
,
_Options
>::
ConstraintRotationalSubspace
::
Matrix3
>::
Type
#endif
operator
*
(
const
typename
InertiaTpl
<
_Scalar
,
_Options
>::
Matrix6
&
Y
,
const
typename
JointSphericalZYXTpl
<
_Scalar
,
_Options
>::
ConstraintRotationalSubspace
&
S
)
{
return
Y
.
template
middleCols
<
3
>(
Inertia
::
ANGULAR
)
*
S
.
S_minimal
;
}
inline
Eigen
::
Matrix
<
double
,
6
,
3
>
operator
*
(
const
Inertia
::
Matrix6
&
Y
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment