Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
P
pinocchio
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
Stack Of Tasks
pinocchio
Commits
327dc143
Commit
327dc143
authored
8 years ago
by
Nicolas Mansard
Committed by
Nicolas Mansard
8 years ago
Browse files
Options
Downloads
Patches
Plain Diff
[C++][Minor] Moved code from fcl.hpp to fcl.hxx to improve readibility.
parent
6a8741e0
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/multibody/fcl.hpp
+10
-26
10 additions, 26 deletions
src/multibody/fcl.hpp
src/multibody/fcl.hxx
+22
-0
22 additions, 0 deletions
src/multibody/fcl.hxx
with
32 additions
and
26 deletions
src/multibody/fcl.hpp
+
10
−
26
View file @
327dc143
...
...
@@ -44,26 +44,10 @@ namespace se3
typedef
std
::
pair
<
GeomIndex
,
GeomIndex
>
Base
;
///
/// \brief Default constructor of a collision pair from two collision object indexes.
/// The indexes must be ordered such that co1 < co2. If not, the constructor reverts the indexes.
///
/// \param[in] co1 Index of the first collision object
/// \param[in] co2 Index of the second collision object
///
CollisionPair
(
const
GeomIndex
co1
,
const
GeomIndex
co2
)
:
Base
(
co1
,
co2
)
{
assert
(
co1
!=
co2
&&
"The index of collision objects must not be equal."
);
}
bool
operator
==
(
const
CollisionPair
&
rhs
)
const
{
return
(
first
==
rhs
.
first
&&
second
==
rhs
.
second
)
||
(
first
==
rhs
.
second
&&
second
==
rhs
.
first
);
}
void
disp
(
std
::
ostream
&
os
)
const
{
os
<<
"collision pair ("
<<
first
<<
","
<<
second
<<
")
\n
"
;
}
friend
std
::
ostream
&
operator
<<
(
std
::
ostream
&
os
,
const
CollisionPair
&
X
);
CollisionPair
(
const
GeomIndex
co1
,
const
GeomIndex
co2
);
bool
operator
==
(
const
CollisionPair
&
rhs
)
const
;
void
disp
(
std
::
ostream
&
os
)
const
;
friend
std
::
ostream
&
operator
<<
(
std
::
ostream
&
os
,
const
CollisionPair
&
X
);
};
// struct CollisionPair
...
...
@@ -136,12 +120,12 @@ struct GeometryObject
GeometryObject
&
operator
=
(
const
GeometryObject
&
other
)
{
name
=
other
.
name
;
parentFrame
=
other
.
parentFrame
;
parentJoint
=
other
.
parentJoint
;
collision_geometry
=
other
.
collision_geometry
;
placement
=
other
.
placement
;
mesh_path
=
other
.
mesh_path
;
name
=
other
.
name
;
parentFrame
=
other
.
parentFrame
;
parentJoint
=
other
.
parentJoint
;
collision_geometry
=
other
.
collision_geometry
;
placement
=
other
.
placement
;
mesh_path
=
other
.
mesh_path
;
return
*
this
;
}
...
...
This diff is collapsed.
Click to expand it.
src/multibody/fcl.hxx
+
22
−
0
View file @
327dc143
...
...
@@ -25,6 +25,28 @@
namespace
se3
{
///
/// \brief Default constructor of a collision pair from two collision object indexes.
/// The indexes must be ordered such that co1 < co2. If not, the constructor reverts the indexes.
///
/// \param[in] co1 Index of the first collision object
/// \param[in] co2 Index of the second collision object
///
inline
CollisionPair
::
CollisionPair
(
const
GeomIndex
co1
,
const
GeomIndex
co2
)
:
Base
(
co1
,
co2
)
{
assert
(
co1
!=
co2
&&
"The index of collision objects must not be equal."
);
}
inline
bool
CollisionPair
::
operator
==
(
const
CollisionPair
&
rhs
)
const
{
return
(
first
==
rhs
.
first
&&
second
==
rhs
.
second
)
||
(
first
==
rhs
.
second
&&
second
==
rhs
.
first
);
}
inline
void
CollisionPair
::
disp
(
std
::
ostream
&
os
)
const
{
os
<<
"collision pair ("
<<
first
<<
","
<<
second
<<
")
\n
"
;
}
inline
std
::
ostream
&
operator
<<
(
std
::
ostream
&
os
,
const
CollisionPair
&
X
)
{
X
.
disp
(
os
);
return
os
;
...
...
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