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
7d39ac95
Unverified
Commit
7d39ac95
authored
5 years ago
by
Justin Carpentier
Committed by
GitHub
5 years ago
Browse files
Options
Downloads
Plain Diff
Merge pull request #1053 from jcarpent/devel
Fix literal warning in Python 3.8
parents
bda773d9
2254eb5c
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
bindings/python/algorithm/expose-geometry.cpp
+13
-12
13 additions, 12 deletions
bindings/python/algorithm/expose-geometry.cpp
bindings/python/pinocchio/visualize/gepetto_visualizer.py
+1
-1
1 addition, 1 deletion
bindings/python/pinocchio/visualize/gepetto_visualizer.py
with
14 additions
and
13 deletions
bindings/python/algorithm/expose-geometry.cpp
+
13
−
12
View file @
7d39ac95
//
// Copyright (c) 2015-20
16
CNRS
// Copyright (c) 2015-20
20
CNRS
INRIA
//
#include
"pinocchio/bindings/python/algorithm/algorithms.hpp"
...
...
@@ -16,51 +16,51 @@ namespace pinocchio
bp
::
def
(
"updateGeometryPlacements"
,
&
updateGeometryPlacements
<
double
,
0
,
JointCollectionDefaultTpl
,
VectorXd
>
,
bp
::
args
(
"model"
,
"data"
,
"geometry
model"
,
"geometry
data"
,
"
Configuration vector q (size Model::nq)
"
),
bp
::
args
(
"model"
,
"data"
,
"geometry
_
model"
,
"geometry
_
data"
,
"
q
"
),
"Update the placement of the collision objects according to the current configuration."
"The algorithm also updates the current placement of the joint in Data."
);
bp
::
def
(
"updateGeometryPlacements"
,
&
updateGeometryPlacements
<
double
,
0
,
JointCollectionDefaultTpl
>
,
bp
::
args
(
"model"
,
"data"
,
"geometry
model"
,
"geometry
data"
),
bp
::
args
(
"model"
,
"data"
,
"geometry
_
model"
,
"geometry
_
data"
),
"Update the placement of the collision objects according to the current joint placement stored in data."
);
bp
::
def
(
"setGeometryMeshScales"
,
(
void
(
*
)(
GeometryModel
&
,
const
Vector3d
&
))
&
setGeometryMeshScales
<
Vector3d
>
,
bp
::
args
(
"geometry
model"
,
"scale"
),
bp
::
args
(
"geometry
_
model"
,
"scale"
),
"Set a mesh scaling vector to each GeometryObject contained in the the GeometryModel."
);
bp
::
def
(
"setGeometryMeshScales"
,
(
void
(
*
)(
GeometryModel
&
,
const
double
))
&
setGeometryMeshScales
,
bp
::
args
(
"geometry
model"
,
"scale"
),
bp
::
args
(
"geometry
_
model"
,
"scale"
),
"Set an isotropic mesh scaling to each GeometryObject contained in the the GeometryModel."
);
#ifdef PINOCCHIO_WITH_HPP_FCL
bp
::
def
(
"computeCollision"
,
computeCollision
,
bp
::
args
(
"geometry
model"
,
"geometry
data"
,
"
collision
pair
index"
),
bp
::
args
(
"geometry
_
model"
,
"geometry
_
data"
,
"pair
_
index"
),
"Check if the collision objects of a collision pair for a given Geometry Model and Data are in collision."
"The collision pair is given by the two index of the collision objects."
);
bp
::
def
(
"computeCollisions"
,
(
bool
(
*
)(
const
GeometryModel
&
,
GeometryData
&
,
const
bool
))
&
computeCollisions
,
bp
::
args
(
"geometry
model"
,
"geometry
data"
,
"stop
at
first
collision"
),
bp
::
args
(
"geometry
_
model"
,
"geometry
_
data"
,
"stop
_
at
_
first
_
collision"
),
"Determine if collision pairs are effectively in collision."
);
bp
::
def
(
"computeCollisions"
,
&
computeCollisions
<
double
,
0
,
JointCollectionDefaultTpl
,
VectorXd
>
,
bp
::
args
(
"model"
,
"data"
,
"geometry
model"
,
"geometry
data"
,
"
Configuration q (size Model::nq)
"
,
"bool"
),
bp
::
args
(
"model"
,
"data"
,
"geometry
_
model"
,
"geometry
_
data"
,
"
q
"
,
"bool"
),
"Update the geometry for a given configuration and"
"determine if all collision pairs are effectively in collision or not."
);
bp
::
def
(
"computeDistance"
,
&
computeDistance
,
bp
::
args
(
"geometry
model"
,
"geometry
data"
,
"pair
I
ndex"
),
bp
::
args
(
"geometry
_
model"
,
"geometry
_
data"
,
"pair
_i
ndex"
),
"Compute the distance between the two geometry objects of a given collision pair for a GeometryModel and associated GeometryData."
,
bp
::
return_value_policy
<
bp
::
return_by_value
>
()
// bp::with_custodian_and_ward_postcall<0,1>()
...
...
@@ -68,17 +68,18 @@ namespace pinocchio
bp
::
def
(
"computeDistances"
,
(
std
::
size_t
(
*
)(
const
GeometryModel
&
,
GeometryData
&
))
&
computeDistances
,
bp
::
args
(
"geometry
model"
,
"geometry
data"
),
bp
::
args
(
"geometry
_
model"
,
"geometry
_
data"
),
"Compute the distance between each collision pair for a given GeometryModel and associated GeometryData."
);
bp
::
def
(
"computeDistances"
,
&
computeDistances
<
double
,
0
,
JointCollectionDefaultTpl
,
VectorXd
>
,
bp
::
args
(
"model"
,
"data"
,
"geometry
model"
,
"geometry
data"
,
"
Configuration q (size Model::nq)
"
),
bp
::
args
(
"model"
,
"data"
,
"geometry
_
model"
,
"geometry
_
data"
,
"
q
"
),
"Update the geometry for a given configuration and"
"compute the distance between each collision pair"
);
#endif // PINOCCHIO_WITH_HPP_FCL
#endif // PINOCCHIO_WITH_HPP_FCL
}
}
// namespace python
}
// namespace pinocchio
This diff is collapsed.
Click to expand it.
bindings/python/pinocchio/visualize/gepetto_visualizer.py
+
1
−
1
View file @
7d39ac95
...
...
@@ -102,7 +102,7 @@ class GepettoVisualizer(BaseVisualizer):
gui
.
setScale
(
meshName
,
npToTuple
(
meshScale
))
if
geometry_object
.
overrideMaterial
:
gui
.
setColor
(
meshName
,
npToTuple
(
meshColor
))
if
meshTexturePath
is
not
''
:
if
meshTexturePath
!=
''
:
gui
.
setTexture
(
meshName
,
meshTexturePath
)
def
loadViewerModel
(
self
,
rootNodeName
=
"
pinocchio
"
):
...
...
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