Make 3 the default number of channels in mjsTexture.
PiperOrigin-RevId: 679521155 Change-Id: Ie6c962e75983c8bf8323170338b3d480be3a1117
This commit is contained in:
committed by
Copybara-Service
parent
6a415da267
commit
bb6da503dc
@@ -3236,9 +3236,7 @@ void mjXReader::Asset(XMLElement* section, const mjVFS* vfs) {
|
||||
}
|
||||
ReadAttrInt(elem, "width", &texture->width);
|
||||
ReadAttrInt(elem, "height", &texture->height);
|
||||
if (!ReadAttrInt(elem, "nchannel", &texture->nchannel)) {
|
||||
texture->nchannel = 3;
|
||||
}
|
||||
ReadAttrInt(elem, "nchannel", &texture->nchannel);
|
||||
ReadAttr(elem, "rgb1", 3, texture->rgb1, text);
|
||||
ReadAttr(elem, "rgb2", 3, texture->rgb2, text);
|
||||
ReadAttr(elem, "markrgb", 3, texture->markrgb, text);
|
||||
|
||||
Reference in New Issue
Block a user