Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Gepetto
aicp_mapping
Commits
dd3fd5c3
Commit
dd3fd5c3
authored
Mar 30, 2019
by
simalpha
Browse files
Added constant references.
parent
aebb4059
Changes
2
Hide whitespace changes
Inline
Side-by-side
aicp_core/include/aicp_utils/common.hpp
View file @
dd3fd5c3
...
...
@@ -23,8 +23,8 @@
Eigen
::
Isometry3d
fromMatrix4fToIsometry3d
(
Eigen
::
Matrix4f
matrix
);
//compute angle between two vecotrs (returns degrees)
double
angleBetweenVectors2d
(
Eigen
::
Vector2d
&
v1
,
Eigen
::
Vector2d
&
v2
);
double
angleBetweenVectors2d
(
const
Eigen
::
Vector2d
&
v1
,
const
Eigen
::
Vector2d
&
v2
);
//swapping two values.
template
<
typename
T
>
...
...
aicp_core/src/utils/common.cpp
View file @
dd3fd5c3
...
...
@@ -22,9 +22,8 @@ Eigen::Isometry3d fromMatrix4fToIsometry3d(Eigen::Matrix4f matrix){
return
isometry
;
}
double
angleBetweenVectors2d
(
Eigen
::
Vector2d
&
v1
,
Eigen
::
Vector2d
&
v2
){
double
angleBetweenVectors2d
(
const
Eigen
::
Vector2d
&
v1
,
const
Eigen
::
Vector2d
&
v2
){
return
atan2
(
v1
(
0
)
*
v2
(
1
)
-
v1
(
1
)
*
v2
(
0
),
v1
(
0
)
*
v2
(
0
)
+
v1
(
1
)
*
v2
(
1
))
*
180.0
/
M_PI
;
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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