Add support for querying of MjsTendon path from Python.
Fixes #2670 PiperOrigin-RevId: 822215254 Change-Id: Ice5a264e54f963776093511c6e4ac830aae6d4f8
This commit is contained in:
committed by
Copybara-Service
parent
2f65e23779
commit
ac2cd5dfd6
@@ -10471,6 +10471,66 @@ FUNCTIONS: Mapping[str, FunctionDecl] = dict([
|
||||
),
|
||||
doc="Return spec's next element; return NULL if element is last.",
|
||||
)),
|
||||
('mjs_getWrapTarget',
|
||||
FunctionDecl(
|
||||
name='mjs_getWrapTarget',
|
||||
return_type=PointerType(
|
||||
inner_type=ValueType(name='mjsElement'),
|
||||
),
|
||||
parameters=(
|
||||
FunctionParameterDecl(
|
||||
name='wrap',
|
||||
type=PointerType(
|
||||
inner_type=ValueType(name='mjsWrap'),
|
||||
),
|
||||
),
|
||||
),
|
||||
doc='Get wrapped element in tendon path.',
|
||||
)),
|
||||
('mjs_getWrapSideSite',
|
||||
FunctionDecl(
|
||||
name='mjs_getWrapSideSite',
|
||||
return_type=PointerType(
|
||||
inner_type=ValueType(name='mjsSite'),
|
||||
),
|
||||
parameters=(
|
||||
FunctionParameterDecl(
|
||||
name='wrap',
|
||||
type=PointerType(
|
||||
inner_type=ValueType(name='mjsWrap'),
|
||||
),
|
||||
),
|
||||
),
|
||||
doc='Get wrapped element side site in tendon path if it has one, nullptr otherwise.', # pylint: disable=line-too-long
|
||||
)),
|
||||
('mjs_getWrapDivisor',
|
||||
FunctionDecl(
|
||||
name='mjs_getWrapDivisor',
|
||||
return_type=ValueType(name='double'),
|
||||
parameters=(
|
||||
FunctionParameterDecl(
|
||||
name='wrap',
|
||||
type=PointerType(
|
||||
inner_type=ValueType(name='mjsWrap'),
|
||||
),
|
||||
),
|
||||
),
|
||||
doc='Get divisor of mjsWrap wrapping a puller.',
|
||||
)),
|
||||
('mjs_getWrapCoef',
|
||||
FunctionDecl(
|
||||
name='mjs_getWrapCoef',
|
||||
return_type=ValueType(name='double'),
|
||||
parameters=(
|
||||
FunctionParameterDecl(
|
||||
name='wrap',
|
||||
type=PointerType(
|
||||
inner_type=ValueType(name='mjsWrap'),
|
||||
),
|
||||
),
|
||||
),
|
||||
doc='Get coefficient of mjsWrap wrapping a joint.',
|
||||
)),
|
||||
('mjs_setName',
|
||||
FunctionDecl(
|
||||
name='mjs_setName',
|
||||
@@ -10794,6 +10854,40 @@ FUNCTIONS: Mapping[str, FunctionDecl] = dict([
|
||||
),
|
||||
doc='Get double array contents and optionally its size.',
|
||||
)),
|
||||
('mjs_getWrapNum',
|
||||
FunctionDecl(
|
||||
name='mjs_getWrapNum',
|
||||
return_type=ValueType(name='int'),
|
||||
parameters=(
|
||||
FunctionParameterDecl(
|
||||
name='tendonspec',
|
||||
type=PointerType(
|
||||
inner_type=ValueType(name='mjsTendon', is_const=True),
|
||||
),
|
||||
),
|
||||
),
|
||||
doc='Get number of elements a tendon wraps.',
|
||||
)),
|
||||
('mjs_getWrap',
|
||||
FunctionDecl(
|
||||
name='mjs_getWrap',
|
||||
return_type=PointerType(
|
||||
inner_type=ValueType(name='mjsWrap'),
|
||||
),
|
||||
parameters=(
|
||||
FunctionParameterDecl(
|
||||
name='tendonspec',
|
||||
type=PointerType(
|
||||
inner_type=ValueType(name='mjsTendon', is_const=True),
|
||||
),
|
||||
),
|
||||
FunctionParameterDecl(
|
||||
name='i',
|
||||
type=ValueType(name='int'),
|
||||
),
|
||||
),
|
||||
doc='Get mjsWrap element at position i in the tendon path.',
|
||||
)),
|
||||
('mjs_getPluginAttributes',
|
||||
FunctionDecl(
|
||||
name='mjs_getPluginAttributes',
|
||||
|
||||
Reference in New Issue
Block a user