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
Guilhem Saurel
pinocchio
Commits
e1891980
Commit
e1891980
authored
Jan 05, 2017
by
Joseph Mirabel
Committed by
Joseph Mirabel
Jan 05, 2017
Browse files
[Minor][C++] Add precision argument in defineSameRotation(Quat,Quat)
parent
81d11699
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/math/quaternion.hpp
View file @
e1891980
...
...
@@ -56,9 +56,10 @@ namespace se3
///
template
<
typename
Derived
,
typename
otherDerived
>
bool
defineSameRotation
(
const
Eigen
::
QuaternionBase
<
Derived
>
&
q1
,
const
Eigen
::
QuaternionBase
<
otherDerived
>
&
q2
)
const
Eigen
::
QuaternionBase
<
otherDerived
>
&
q2
,
const
typename
Derived
::
RealScalar
&
prec
=
Eigen
::
NumTraits
<
typename
Derived
::
Scalar
>::
dummy_precision
())
{
return
(
q1
.
coeffs
().
isApprox
(
q2
.
coeffs
())
||
q1
.
coeffs
().
isApprox
(
-
q2
.
coeffs
())
);
return
(
q1
.
coeffs
().
isApprox
(
q2
.
coeffs
()
,
prec
)
||
q1
.
coeffs
().
isApprox
(
-
q2
.
coeffs
()
,
prec
)
);
}
/// Approximately normalize by applying the first order limited development
...
...
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