Add realtime parameter to visual global.
PiperOrigin-RevId: 478775714 Change-Id: Ic2d178a5c57d298d005215219ce8470392c4651b
This commit is contained in:
committed by
Copybara-Service
parent
f85cfb8ed2
commit
bc1490b7a8
@@ -109,8 +109,8 @@ static const char* MJCF[nMJCF][mjXATTRNUM] = {
|
||||
|
||||
{"visual", "*", "0"},
|
||||
{"<"},
|
||||
{"global", "?", "8", "fovy", "ipd", "azimuth", "elevation", "linewidth", "glow", "offwidth",
|
||||
"offheight"},
|
||||
{"global", "?", "9", "fovy", "ipd", "azimuth", "elevation", "linewidth", "glow", "offwidth",
|
||||
"offheight", "realtime"},
|
||||
{"quality", "?", "5", "shadowsize", "offsamples", "numslices", "numstacks",
|
||||
"numquads"},
|
||||
{"headlight", "?", "4", "ambient", "diffuse", "specular", "active"},
|
||||
@@ -2172,6 +2172,10 @@ void mjXReader::Visual(XMLElement* section) {
|
||||
ReadAttr(elem, "glow", 1, &vis->global.glow, text);
|
||||
ReadAttrInt(elem, "offwidth", &vis->global.offwidth);
|
||||
ReadAttrInt(elem, "offheight", &vis->global.offheight);
|
||||
if (ReadAttr(elem, "realtime", 1, &vis->global.realtime, text))
|
||||
if (vis->global.realtime<=0) {
|
||||
throw mjXError(elem, "realtime must be greater than 0");
|
||||
}
|
||||
}
|
||||
|
||||
// quality sub-element
|
||||
|
||||
Reference in New Issue
Block a user