Automated g4 rollback of changelist 604607692.
*** Reason for rollback *** breakage resulting in "inertia must have positive eigenvalues" when parsing URDF's *** Original change description *** Move fullinertia from mjCAlternative to mjCBody. *** PiperOrigin-RevId: 604677400 Change-Id: Iab8263b5b0aee310bd75404e314f3b707ce3300e
This commit is contained in:
committed by
Copybara-Service
parent
737342bdfe
commit
84f20ffb66
+5
-6
@@ -51,15 +51,14 @@ void mjXBase::SetModel(mjCModel* _model) {
|
||||
|
||||
|
||||
// read alternative orientation specification
|
||||
int mjXBase::ReadAlternative(XMLElement* elem, mjmOrientation& alt) {
|
||||
void mjXBase::ReadAlternative(XMLElement* elem, mjmOrientation& alt) {
|
||||
string text;
|
||||
int read = (int)(elem->Attribute("quat") != 0) +
|
||||
(ReadAttr(elem, "axisangle", 4, alt.axisangle, text) ? 1 : 0) +
|
||||
(ReadAttr(elem, "xyaxes", 6, alt.xyaxes, text) ? 1 : 0) +
|
||||
(ReadAttr(elem, "zaxis", 3, alt.zaxis, text) ? 1 : 0) +
|
||||
(ReadAttr(elem, "euler", 3, alt.euler, text) ? 1 : 0);
|
||||
if (read > 1) {
|
||||
throw mjXError(elem, "multiple orientation specifiers are not allowed");
|
||||
}
|
||||
return read;
|
||||
(ReadAttr(elem, "euler", 3, alt.euler, text) ? 1 : 0) +
|
||||
(ReadAttr(elem, "fullinertia", 6, alt.fullinertia, text) ? 1 : 0);
|
||||
if (read > 1)
|
||||
throw mjXError(elem, "multiple orientation specifiers for the same field are not allowed");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user