Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
H
hpp-fcl
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
Guilhem Saurel
hpp-fcl
Commits
b7ce8b11
Commit
b7ce8b11
authored
8 years ago
by
Javier V. Gomez
Committed by
Florent Lamiraux florent@laas.fr
7 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Remove unecessary inlines, const correctess, and fix indentation
parent
f7e3f831
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
include/hpp/fcl/octree.h
+12
-12
12 additions, 12 deletions
include/hpp/fcl/octree.h
with
12 additions
and
12 deletions
include/hpp/fcl/octree.h
+
12
−
12
View file @
b7ce8b11
...
...
@@ -94,7 +94,7 @@ public:
}
/// @brief get the bounding volume for the root
inline
AABB
getRootBV
()
const
AABB
getRootBV
()
const
{
FCL_REAL
delta
=
(
1
<<
tree
->
getTreeDepth
())
*
tree
->
getResolution
()
/
2
;
...
...
@@ -103,34 +103,34 @@ public:
}
/// @brief get the root node of the octree
inline
OcTreeNode
*
getRoot
()
const
OcTreeNode
*
getRoot
()
const
{
return
tree
->
getRoot
();
}
/// @brief whether one node is completely occupied
inline
bool
isNodeOccupied
(
const
OcTreeNode
*
node
)
const
bool
isNodeOccupied
(
const
OcTreeNode
*
node
)
const
{
// return tree->isNodeOccupied(node)
;
return
node
->
getOccupancy
()
>=
occupancy_threshold
;
}
/// @brief whether one node is completely free
inline
bool
isNodeFree
(
const
OcTreeNode
*
node
)
const
bool
isNodeFree
(
const
OcTreeNode
*
node
)
const
{
// return false; // default no definitely free node
return
node
->
getOccupancy
()
<=
free_threshold
;
}
/// @brief whether one node is uncertain
inline
bool
isNodeUncertain
(
const
OcTreeNode
*
node
)
const
bool
isNodeUncertain
(
const
OcTreeNode
*
node
)
const
{
return
(
!
isNodeOccupied
(
node
))
&&
(
!
isNodeFree
(
node
));
}
/// @brief transform the octree into a bunch of boxes; uncertainty information is kept in the boxes. However, we
/// only keep the occupied boxes (i.e., the boxes whose occupied probability is higher enough).
inline
std
::
vector
<
boost
::
array
<
FCL_REAL
,
6
>
>
toBoxes
()
const
std
::
vector
<
boost
::
array
<
FCL_REAL
,
6
>
>
toBoxes
()
const
{
std
::
vector
<
boost
::
array
<
FCL_REAL
,
6
>
>
boxes
;
boxes
.
reserve
(
tree
->
size
()
/
2
);
...
...
@@ -188,29 +188,29 @@ public:
}
/// @return ptr to child number childIdx of node
inline
OcTreeNode
*
getNodeChild
(
OcTreeNode
*
node
,
unsigned
int
childIdx
)
const
OcTreeNode
*
getNodeChild
(
OcTreeNode
*
node
,
unsigned
int
childIdx
)
{
return
tree
->
getNodeChild
(
node
,
childIdx
);
}
/// @return const ptr to child number childIdx of node
inline
const
OcTreeNode
*
getNodeChild
(
const
OcTreeNode
*
node
,
unsigned
int
childIdx
)
const
const
OcTreeNode
*
getNodeChild
(
const
OcTreeNode
*
node
,
unsigned
int
childIdx
)
const
{
return
tree
->
getNodeChild
(
node
,
childIdx
);
}
/// @brief return true if the child at childIdx exists
inline
bool
nodeChildExists
(
const
OcTreeNode
*
node
,
unsigned
int
childIdx
)
const
bool
nodeChildExists
(
const
OcTreeNode
*
node
,
unsigned
int
childIdx
)
const
{
return
tree
->
nodeChildExists
(
node
,
childIdx
);
}
/// @brief return true if node has at least one child
inline
bool
nodeHasChildren
(
const
OcTreeNode
*
node
)
const
bool
nodeHasChildren
(
const
OcTreeNode
*
node
)
const
{
return
tree
->
nodeHasChildren
(
node
);
return
tree
->
nodeHasChildren
(
node
);
}
/// @brief return object type, it is an octree
OBJECT_TYPE
getObjectType
()
const
{
return
OT_OCTREE
;
}
...
...
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