Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
coal
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
Coal
coal
Commits
7e3690f9
Commit
7e3690f9
authored
5 years ago
by
Joseph Mirabel
Browse files
Options
Downloads
Patches
Plain Diff
Document more functions.
parent
21fbed01
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
python/CMakeLists.txt
+1
-0
1 addition, 0 deletions
python/CMakeLists.txt
python/collision-geometries.cc
+15
-12
15 additions, 12 deletions
python/collision-geometries.cc
python/math.cc
+11
-20
11 additions, 20 deletions
python/math.cc
with
27 additions
and
32 deletions
python/CMakeLists.txt
+
1
−
0
View file @
7e3690f9
...
...
@@ -42,6 +42,7 @@ INCLUDE_DIRECTORIES("${Boost_INCLUDE_DIRS}" ${PYTHON_INCLUDE_DIRS})
# To be run manually:
# make doc
# ./cmake/doxygen/doxygen_xml_parser.py build-rel/doc/doxygen-xml/index.xml > build-rel/python/doxygen_autodoc.hh
INCLUDE_DIRECTORIES
(
"
${
CMAKE_SOURCE_DIR
}
/src"
)
INCLUDE_DIRECTORIES
(
"
${
CMAKE_CURRENT_BINARY_DIR
}
"
)
SET
(
${
LIBRARY_NAME
}
_HEADERS
...
...
This diff is collapsed.
Click to expand it.
python/collision-geometries.cc
+
15
−
12
View file @
7e3690f9
...
...
@@ -43,6 +43,9 @@
#include
<hpp/fcl/shape/convex.h>
#include
<hpp/fcl/BVH/BVH_model.h>
#include
"doxygen_autodoc/hpp/fcl/BVH/BVH_model.h"
#include
"doxygen_autodoc/hpp/fcl/shape/geometric_shapes.h"
using
namespace
boost
::
python
;
using
namespace
hpp
::
fcl
;
...
...
@@ -71,7 +74,7 @@ void exposeBVHModel (const std::string& bvname)
std
::
string
type
=
"BVHModel"
+
bvname
;
class_
<
BVHModel_t
,
bases
<
BVHModelBase
>
,
shared_ptr
<
BVHModel_t
>
>
(
type
.
c_str
(),
init
<>
(
))
(
type
.
c_str
(),
doxygen
::
class_doc
<
BVHModel_t
>
(),
init
<>
(
doxygen
::
constructor_doc
<
BVHModel_t
>
()
))
;
}
...
...
@@ -108,12 +111,12 @@ struct ConvexWrapper
void
exposeShapes
()
{
class_
<
ShapeBase
,
bases
<
CollisionGeometry
>
,
shared_ptr
<
ShapeBase
>
,
noncopyable
>
(
"ShapeBase"
,
no_init
)
(
"ShapeBase"
,
doxygen
::
class_doc
<
ShapeBase
>
(),
no_init
)
//.def ("getObjectType", &CollisionGeometry::getObjectType)
;
class_
<
Box
,
bases
<
ShapeBase
>
,
shared_ptr
<
Box
>
>
(
"Box"
,
init
<>
())
(
"Box"
,
doxygen
::
class_doc
<
ShapeBase
>
(),
init
<>
())
.
def
(
init
<
FCL_REAL
,
FCL_REAL
,
FCL_REAL
>
())
.
def
(
init
<
Vec3f
>
())
.
add_property
(
"halfSide"
,
...
...
@@ -122,19 +125,19 @@ void exposeShapes ()
;
class_
<
Capsule
,
bases
<
ShapeBase
>
,
shared_ptr
<
Capsule
>
>
(
"Capsule"
,
init
<
FCL_REAL
,
FCL_REAL
>
())
(
"Capsule"
,
doxygen
::
class_doc
<
Capsule
>
(),
init
<
FCL_REAL
,
FCL_REAL
>
())
.
def_readwrite
(
"radius"
,
&
Capsule
::
radius
)
.
def_readwrite
(
"halfLength"
,
&
Capsule
::
halfLength
)
;
class_
<
Cone
,
bases
<
ShapeBase
>
,
shared_ptr
<
Cone
>
>
(
"Cone"
,
init
<
FCL_REAL
,
FCL_REAL
>
())
(
"Cone"
,
doxygen
::
class_doc
<
Cone
>
(),
init
<
FCL_REAL
,
FCL_REAL
>
())
.
def_readwrite
(
"radius"
,
&
Cone
::
radius
)
.
def_readwrite
(
"halfLength"
,
&
Cone
::
halfLength
)
;
class_
<
ConvexBase
,
bases
<
ShapeBase
>
,
shared_ptr
<
ConvexBase
>
,
noncopyable
>
(
"ConvexBase"
,
no_init
)
(
"ConvexBase"
,
doxygen
::
class_doc
<
ConvexBase
>
(),
no_init
)
.
def_readonly
(
"center"
,
&
ConvexBase
::
center
)
.
def_readonly
(
"num_points"
,
&
ConvexBase
::
num_points
)
.
def
(
"points"
,
&
ConvexBaseWrapper
::
points
)
...
...
@@ -142,19 +145,19 @@ void exposeShapes ()
;
class_
<
Convex
<
Triangle
>
,
bases
<
ConvexBase
>
,
shared_ptr
<
Convex
<
Triangle
>
>
,
noncopyable
>
(
"Convex"
,
no_init
)
(
"Convex"
,
doxygen
::
class_doc
<
Convex
<
Triangle
>
>
(),
no_init
)
.
def_readonly
(
"num_polygons"
,
&
Convex
<
Triangle
>::
num_polygons
)
.
def
(
"polygons"
,
&
ConvexWrapper
<
Triangle
>::
polygons
)
;
class_
<
Cylinder
,
bases
<
ShapeBase
>
,
shared_ptr
<
Cylinder
>
>
(
"Cylinder"
,
init
<
FCL_REAL
,
FCL_REAL
>
())
(
"Cylinder"
,
doxygen
::
class_doc
<
Cylinder
>
(),
init
<
FCL_REAL
,
FCL_REAL
>
())
.
def_readwrite
(
"radius"
,
&
Cylinder
::
radius
)
.
def_readwrite
(
"halfLength"
,
&
Cylinder
::
halfLength
)
;
class_
<
Halfspace
,
bases
<
ShapeBase
>
,
shared_ptr
<
Halfspace
>
>
(
"Halfspace"
,
"The h
alf
-
space
is defined by {x | n * x < d}."
,
init
<
const
Vec3f
&
,
FCL_REAL
>
())
(
"Halfspace"
,
doxygen
::
class_doc
<
H
alfspace
>
()
,
init
<
const
Vec3f
&
,
FCL_REAL
>
())
.
def
(
init
<
FCL_REAL
,
FCL_REAL
,
FCL_REAL
,
FCL_REAL
>
())
.
def
(
init
<>
())
.
def_readwrite
(
"n"
,
&
Halfspace
::
n
)
...
...
@@ -162,7 +165,7 @@ void exposeShapes ()
;
class_
<
Plane
,
bases
<
ShapeBase
>
,
shared_ptr
<
Plane
>
>
(
"Plane"
,
"The plane is defined by {x | n * x = d}."
,
init
<
const
Vec3f
&
,
FCL_REAL
>
())
(
"Plane"
,
doxygen
::
class_doc
<
Plane
>
()
,
init
<
const
Vec3f
&
,
FCL_REAL
>
())
.
def
(
init
<
FCL_REAL
,
FCL_REAL
,
FCL_REAL
,
FCL_REAL
>
())
.
def
(
init
<>
())
.
def_readwrite
(
"n"
,
&
Plane
::
n
)
...
...
@@ -170,12 +173,12 @@ void exposeShapes ()
;
class_
<
Sphere
,
bases
<
ShapeBase
>
,
shared_ptr
<
Sphere
>
>
(
"Sphere"
,
init
<
FCL_REAL
>
())
(
"Sphere"
,
doxygen
::
class_doc
<
Sphere
>
(),
init
<
FCL_REAL
>
())
.
def_readwrite
(
"radius"
,
&
Sphere
::
radius
)
;
class_
<
TriangleP
,
bases
<
ShapeBase
>
,
shared_ptr
<
TriangleP
>
>
(
"TriangleP"
,
init
<
const
Vec3f
&
,
const
Vec3f
&
,
const
Vec3f
&>
())
(
"TriangleP"
,
doxygen
::
class_doc
<
TriangleP
>
(),
init
<
const
Vec3f
&
,
const
Vec3f
&
,
const
Vec3f
&>
())
.
def_readwrite
(
"a"
,
&
TriangleP
::
a
)
.
def_readwrite
(
"b"
,
&
TriangleP
::
b
)
.
def_readwrite
(
"c"
,
&
TriangleP
::
c
)
...
...
This diff is collapsed.
Click to expand it.
python/math.cc
+
11
−
20
View file @
7e3690f9
...
...
@@ -41,21 +41,10 @@
#include
<hpp/fcl/math/transform.h>
#include
"fcl.hh"
#include
<hpp/fcl/collision.h>
#include
<hpp/fcl/traversal/traversal_node_bvh_shape.h>
#include
<hpp/fcl/traversal/traversal_node_bvhs.h>
#include
<hpp/fcl/traversal/traversal_node_octree.h>
#include
<hpp/fcl/traversal/traversal_node_shapes.h>
#include
<hpp/fcl/mesh_loader/loader.h>
#include
<hpp/fcl/narrowphase/gjk.h>
#include
<hpp/fcl/BVH/BVH_model.h>
#include
<hpp/fcl/octree.h>
#include
<hpp/fcl/profile.h>
#include
"doxygen_autodoc.hh"
using
namespace
boost
::
python
;
#include
"doxygen_autodoc/hpp/fcl/math/transform.h"
using
namespace
boost
::
python
;
using
namespace
hpp
::
fcl
;
struct
TriangleWrapper
...
...
@@ -81,13 +70,15 @@ void exposeMaths ()
if
(
!
eigenpy
::
register_symbolic_link_to_registered_type
<
Eigen
::
AngleAxisd
>
())
eigenpy
::
exposeAngleAxis
();
class_
<
Transform3f
>
(
"Transform3f"
,
init
<>
(
"Default constructor."
))
.
def
(
init
<
Matrix3f
,
Vec3f
>
())
.
def
(
init
<
Quaternion3f
,
Vec3f
>
())
.
def
(
init
<
Matrix3f
>
())
.
def
(
init
<
Quaternion3f
>
())
.
def
(
init
<
Vec3f
>
())
.
def
(
init
<
Transform3f
>
(
args
(
"self"
,
"other"
),
"Copy constructor."
))
eigenpy
::
enableEigenPySpecific
<
Matrix3f
>
();
eigenpy
::
enableEigenPySpecific
<
Vec3f
>
();
class_
<
Transform3f
>
(
"Transform3f"
,
doxygen
::
class_doc
<
Transform3f
>
(),
init
<>
(
doxygen
::
constructor_doc
<
Transform3f
>
()))
.
def
(
init
<
Matrix3f
,
Vec3f
>
(
doxygen
::
constructor_doc
<
Transform3f
,
const
Matrix3f
::
MatrixBase
&
,
const
Vec3f
::
MatrixBase
&>
()))
.
def
(
init
<
Quaternion3f
,
Vec3f
>
(
doxygen
::
constructor_doc
<
Transform3f
,
const
Quaternion3f
&
,
const
Vec3f
::
MatrixBase
&>
()))
.
def
(
init
<
Matrix3f
>
(
doxygen
::
constructor_doc
<
Transform3f
,
const
Matrix3f
&
>
()))
.
def
(
init
<
Quaternion3f
>
(
doxygen
::
constructor_doc
<
Transform3f
,
const
Quaternion3f
&
>
()))
.
def
(
init
<
Vec3f
>
(
doxygen
::
constructor_doc
<
Transform3f
,
const
Vec3f
&
>
()))
.
def
(
"getQuatRotation"
,
&
Transform3f
::
getQuatRotation
,
doxygen
::
member_func_doc
(
&
Transform3f
::
getQuatRotation
))
.
def
(
"getTranslation"
,
&
Transform3f
::
getTranslation
,
doxygen
::
member_func_doc
(
&
Transform3f
::
getTranslation
),
return_value_policy
<
copy_const_reference
>
())
...
...
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