Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
H
hpp-manipulation
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Humanoid Path Planner
hpp-manipulation
Commits
5e3f84e6
Commit
5e3f84e6
authored
8 years ago
by
Joseph Mirabel
Committed by
Joseph Mirabel
8 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Fix broken const-correctness
parent
d83c96ab
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
include/hpp/manipulation/connected-component.hh
+2
-1
2 additions, 1 deletion
include/hpp/manipulation/connected-component.hh
src/connected-component.cc
+7
-8
7 additions, 8 deletions
src/connected-component.cc
src/roadmap.cc
+1
-1
1 addition, 1 deletion
src/roadmap.cc
with
10 additions
and
10 deletions
include/hpp/manipulation/connected-component.hh
+
2
−
1
View file @
5e3f84e6
...
...
@@ -49,12 +49,13 @@ class HPP_MANIPULATION_DLLAPI ConnectedComponent : public core::ConnectedCompone
/// \param roadmap node to be added
void
addNode
(
const
core
::
NodePtr_t
&
node
);
RoadmapNodes_t
getRoadmapNodes
(
const
graph
::
NodePtr_t
graphNode
);
const
RoadmapNodes_t
&
getRoadmapNodes
(
const
graph
::
NodePtr_t
graphNode
)
const
;
protected
:
private
:
GraphNodes_t
graphNodeMap_
;
RoadmapPtr_t
roadmap_
;
static
RoadmapNodes_t
empty_
;
};
// class ConnectedComponent
}
// namespace manipulation
}
// namespace hpp
...
...
This diff is collapsed.
Click to expand it.
src/connected-component.cc
+
7
−
8
View file @
5e3f84e6
...
...
@@ -23,6 +23,7 @@
namespace
hpp
{
namespace
manipulation
{
RoadmapNodes_t
ConnectedComponent
::
empty_
=
RoadmapNodes_t
();
ConnectedComponentPtr_t
ConnectedComponent
::
create
(
const
RoadmapWkPtr_t
&
roadmap
)
{
...
...
@@ -74,17 +75,15 @@ namespace hpp {
}
RoadmapNodes_t
ConnectedComponent
::
getRoadmapNodes
(
const
graph
::
NodePtr_t
graphNode
)
const
RoadmapNodes_t
&
ConnectedComponent
::
getRoadmapNodes
(
const
graph
::
NodePtr_t
graphNode
)
const
{
RoadmapNodes_t
res
;
GraphNodes_t
::
iterator
mapIt
=
graphNodeMap_
.
find
(
graphNode
);
if
(
mapIt
!=
graphNodeMap_
.
end
())
{
res
=
mapIt
->
second
;
}
return
res
;
GraphNodes_t
::
const_iterator
mapIt
=
graphNodeMap_
.
find
(
graphNode
);
if
(
mapIt
!=
graphNodeMap_
.
end
())
return
mapIt
->
second
;
return
empty_
;
}
}
// namespace manipulation
}
// namespace hpp
This diff is collapsed.
Click to expand it.
src/roadmap.cc
+
1
−
1
View file @
5e3f84e6
...
...
@@ -83,7 +83,7 @@ namespace hpp {
{
core
::
NodePtr_t
result
=
NULL
;
minDistance
=
std
::
numeric_limits
<
value_type
>::
infinity
();
RoadmapNodes_t
roadmapNodes
=
connectedComponent
->
getRoadmapNodes
(
node
);
const
RoadmapNodes_t
&
roadmapNodes
=
connectedComponent
->
getRoadmapNodes
(
node
);
for
(
RoadmapNodes_t
::
const_iterator
itNode
=
roadmapNodes
.
begin
();
itNode
!=
roadmapNodes
.
end
();
++
itNode
)
{
value_type
d
=
(
*
distance
())
(
*
(
*
itNode
)
->
configuration
(),
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment