Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Pierre Fernbach
tsid
Commits
768a903a
Commit
768a903a
authored
Mar 21, 2019
by
Julian Viereck
Browse files
Expose TaskSE3Equality::useLocalFrame to python
parent
5f7453c5
Changes
1
Hide whitespace changes
Inline
Side-by-side
bindings/python/tasks/task-se3-equality.hpp
View file @
768a903a
...
...
@@ -31,16 +31,16 @@
namespace
tsid
{
namespace
python
{
{
namespace
bp
=
boost
::
python
;
template
<
typename
TaskSE3
>
struct
TaskSE3EqualityPythonVisitor
:
public
boost
::
python
::
def_visitor
<
TaskSE3EqualityPythonVisitor
<
TaskSE3
>
>
{
template
<
class
PyClass
>
template
<
class
PyClass
>
void
visit
(
PyClass
&
cl
)
const
{
...
...
@@ -62,6 +62,7 @@ namespace tsid
.
def
(
"setKd"
,
&
TaskSE3EqualityPythonVisitor
::
setKd
,
bp
::
arg
(
"Kd"
))
.
def
(
"compute"
,
&
TaskSE3EqualityPythonVisitor
::
compute
,
bp
::
args
(
"t"
,
"q"
,
"v"
,
"data"
))
.
def
(
"getConstraint"
,
&
TaskSE3EqualityPythonVisitor
::
getConstraint
)
.
def
(
"useLocalFrame"
,
&
TaskSE3EqualityPythonVisitor
::
useLocalFrame
,
bp
::
arg
(
"local_frame"
))
.
add_property
(
"frame_id"
,
&
TaskSE3
::
frame_id
,
"frame id return"
)
.
add_property
(
"name"
,
&
TaskSE3EqualityPythonVisitor
::
name
)
;
...
...
@@ -79,6 +80,9 @@ namespace tsid
math
::
ConstraintEquality
cons
(
self
.
getConstraint
().
name
(),
self
.
getConstraint
().
matrix
(),
self
.
getConstraint
().
vector
());
return
cons
;
}
static
void
useLocalFrame
(
TaskSE3
&
self
,
const
bool
local_frame
)
{
self
.
useLocalFrame
(
local_frame
);
}
static
void
setReference
(
TaskSE3
&
self
,
trajectories
::
TrajectorySample
&
ref
){
self
.
setReference
(
ref
);
}
...
...
@@ -105,13 +109,13 @@ namespace tsid
}
static
const
Eigen
::
VectorXd
&
velocity_ref
(
const
TaskSE3
&
self
){
return
self
.
velocity_ref
();
}
}
static
const
Eigen
::
VectorXd
&
Kp
(
TaskSE3
&
self
){
return
self
.
Kp
();
}
}
static
const
Eigen
::
VectorXd
&
Kd
(
TaskSE3
&
self
){
return
self
.
Kd
();
}
}
static
void
setKp
(
TaskSE3
&
self
,
const
::
Eigen
::
VectorXd
Kp
){
return
self
.
Kp
(
Kp
);
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment