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-pinocchio
Commits
7be6f5d0
Commit
7be6f5d0
authored
May 14, 2020
by
Joseph Mirabel
Browse files
Add guards on the version of hpp-fcl.
parent
d08c5b39
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/device.cc
View file @
7be6f5d0
...
@@ -514,6 +514,7 @@ namespace hpp {
...
@@ -514,6 +514,7 @@ namespace hpp {
void
replaceGeometryByConvexHull
(
GeomModel
&
gmodel
,
void
replaceGeometryByConvexHull
(
GeomModel
&
gmodel
,
const
std
::
vector
<
std
::
string
>&
gnames
)
const
std
::
vector
<
std
::
string
>&
gnames
)
{
{
#if HPP_FCL_VERSION_AT_LEAST(1,4,5)
for
(
std
::
size_t
i
=
0
;
i
<
gnames
.
size
();
++
i
)
{
for
(
std
::
size_t
i
=
0
;
i
<
gnames
.
size
();
++
i
)
{
if
(
!
gmodel
.
existGeometryName
(
gnames
[
i
]))
if
(
!
gmodel
.
existGeometryName
(
gnames
[
i
]))
throw
std
::
invalid_argument
(
"Geometry "
+
gnames
[
i
]
+
" does not "
throw
std
::
invalid_argument
(
"Geometry "
+
gnames
[
i
]
+
" does not "
...
@@ -528,6 +529,10 @@ namespace hpp {
...
@@ -528,6 +529,10 @@ namespace hpp {
go
.
geometry
=
bvh
->
convex
;
go
.
geometry
=
bvh
->
convex
;
}
}
}
}
#else
throw
std
::
logic_error
(
"hpp-fcl version is below 1.4.5 does not support "
"the generation of convex hulls."
);
#endif
}
}
#if __cplusplus > 201103L
#if __cplusplus > 201103L
...
...
Write
Preview
Supports
Markdown
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