Add a number of missing struct fields to Python bindings.
It is quite possible that there are a few other fields still missing since we currently do not yet have automated testing of struct field existence. Fixes #747. PiperOrigin-RevId: 517189048 Change-Id: I7c1d95e700eaea05aaa3cde1fd05e1a259553117
This commit is contained in:
committed by
Copybara-Service
parent
a04c4314fd
commit
e20ab6c96f
+2
-1
@@ -48,9 +48,10 @@ Python bindings
|
||||
|
||||
- Fixed IPython history corruption when using ``launch_repl``. The ``launch_repl`` function now provides seamless
|
||||
continuation of an IPython interactive shell session, and is no longer considered experimental feature.
|
||||
- Remove ``efc_`` fields from joint indexers. Since the introduction of arena memory, these fields now have dynamic
|
||||
- Removed ``efc_`` fields from joint indexers. Since the introduction of arena memory, these fields now have dynamic
|
||||
sizes that change between time steps depending on the number of active constraints, breaking strict correspondence
|
||||
between joints and ``efc_`` rows.
|
||||
- Added a number of missing fields to the bindings of ``mjVisual`` and ``mjvPerturb`` structs.
|
||||
|
||||
Simulate
|
||||
^^^^^^^^
|
||||
|
||||
@@ -983,6 +983,7 @@ MjvPerturbWrapper::MjWrapper()
|
||||
}()),
|
||||
X(refpos),
|
||||
X(refquat),
|
||||
X(refselpos),
|
||||
X(localpos) {}
|
||||
#undef X
|
||||
|
||||
@@ -1299,8 +1300,11 @@ PYBIND11_MODULE(_structs, m) {
|
||||
#define X(var) mjVisualGlobal.def_readwrite(#var, &raw::MjVisualGlobal::var)
|
||||
X(fovy);
|
||||
X(ipd);
|
||||
X(azimuth);
|
||||
X(elevation);
|
||||
X(linewidth);
|
||||
X(glow);
|
||||
X(realtime);
|
||||
X(offwidth);
|
||||
X(offheight);
|
||||
#undef X
|
||||
@@ -1966,11 +1970,14 @@ This is useful for example when the MJB is not available as a file on disk.)"));
|
||||
X(skinselect);
|
||||
X(active);
|
||||
X(active2);
|
||||
X(localmass);
|
||||
X(scale);
|
||||
#undef X
|
||||
|
||||
#define X(var) DefinePyArray(mjvPerturb, #var, &MjvPerturbWrapper::var)
|
||||
X(refpos);
|
||||
X(refquat);
|
||||
X(refselpos);
|
||||
X(localpos);
|
||||
#undef X
|
||||
|
||||
|
||||
@@ -611,6 +611,7 @@ class MjWrapper<raw::MjvPerturb> : public WrapperBase<raw::MjvPerturb> {
|
||||
#define X(var) py_array_or_tuple_t<mjtNum> var
|
||||
X(refpos);
|
||||
X(refquat);
|
||||
X(refselpos);
|
||||
X(localpos);
|
||||
#undef X
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user