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
Humanoid Path Planner
hpp-model
Commits
26fda7a0
Commit
26fda7a0
authored
Aug 31, 2015
by
Florent Lamiraux
Browse files
Add operator* between fcl:matrix3f and eigen::matrix_t.
This operator is used to convert from fcl to eigen.
parent
484fad33
Changes
1
Hide whitespace changes
Inline
Side-by-side
include/hpp/model/fcl-to-eigen.hh
View file @
26fda7a0
...
...
@@ -40,6 +40,23 @@ inline hpp::model::matrix_t operator* (const hpp::model::matrix_t& m1,
return
result
;
}
inline
hpp
::
model
::
matrix_t
operator
*
(
const
fcl
::
Matrix3f
&
m1
,
const
hpp
::
model
::
matrix_t
&
m2
)
{
assert
(
m2
.
rows
()
==
3
);
std
::
size_t
cols
=
m2
.
cols
();
hpp
::
model
::
matrix_t
result
(
3
,
cols
);
for
(
std
::
size_t
i
=
0
;
i
<
3
;
++
i
)
{
for
(
std
::
size_t
k
=
0
;
k
<
cols
;
++
k
)
{
result
(
i
,
k
)
=
0
;
for
(
std
::
size_t
j
=
0
;
j
<
3
;
++
j
)
{
result
(
i
,
k
)
+=
m1
(
i
,
j
)
*
m2
(
j
,
k
);
}
}
}
return
result
;
}
namespace
hpp
{
namespace
model
{
inline
void
toEigen
(
const
hpp
::
model
::
vector3_t
&
v
,
...
...
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