Add equivalent inertia ellipsoid visualization.

PiperOrigin-RevId: 519154067
Change-Id: I35f1993c1493df9be752b7163385004649498070
This commit is contained in:
Kevin Zakka
2023-03-24 08:46:58 -07:00
committed by Copybara-Service
parent 2a471d1e11
commit 3f14d97f6b
13 changed files with 60 additions and 17 deletions
+1
View File
@@ -887,6 +887,7 @@ void mjXWriter::Visual(XMLElement* root) {
WriteAttr(elem, "realtime", 1, &vis->global.realtime, &visdef.global.realtime);
WriteAttrInt(elem, "offwidth", vis->global.offwidth, visdef.global.offwidth);
WriteAttrInt(elem, "offheight", vis->global.offheight, visdef.global.offheight);
WriteAttrKey(elem, "ellipsoidinertia", bool_map, 2, vis->global.ellipsoidinertia, visdef.global.ellipsoidinertia);
if (!elem->FirstAttribute()) {
section->DeleteChild(elem);
}