Rename nstack to narena, change it and pstack to count bytes.
PiperOrigin-RevId: 561066311 Change-Id: I4d0e645e6c254dd906bfc42159e0e99149a7c6c8
This commit is contained in:
committed by
Copybara-Service
parent
b979a26b10
commit
daa2ac7f8b
@@ -78,7 +78,7 @@ constexpr auto XArrayShapeImpl(const std::string_view dim1_str) {
|
||||
}
|
||||
|
||||
inline std::size_t NConMax(const mjData* d) {
|
||||
return d->nstack * sizeof(mjtNum) / sizeof(mjContact);
|
||||
return d->narena / sizeof(mjContact);
|
||||
}
|
||||
} // namespace
|
||||
|
||||
@@ -459,7 +459,7 @@ MjModelWrapper MjModelWrapper::Deserialize(std::istream& input) {
|
||||
throw py::value_error("Incompatible serialization version.");
|
||||
}
|
||||
|
||||
int model_size = ReadInt(input);
|
||||
std::size_t model_size = ReadInt(input);
|
||||
CheckInput(input, "mjModel");
|
||||
if (model_size < 0) {
|
||||
throw py::value_error("Invalid serialized mjModel.");
|
||||
|
||||
Reference in New Issue
Block a user