Remove user_objetcs and user_model includes from xml_urdf.

PiperOrigin-RevId: 609330384
Change-Id: I19b330e4063d3be4401dcf1b2b957b55e0616037
This commit is contained in:
Alessio Quaglino
2024-02-22 04:53:54 -08:00
committed by Copybara-Service
parent 5fe3e169ab
commit 34d4a69027
3 changed files with 23 additions and 8 deletions
+12
View File
@@ -370,6 +370,18 @@ mjmBody* mjm_findChild(mjmBody* bodyspec, const char* name) {
// find mesh by name
mjmMesh* mjm_findMesh(mjmModel* modelspec, const char* name) {
mjCModel* model = reinterpret_cast<mjCModel*>(modelspec->element);
mjCMesh* mesh = (mjCMesh*)model->FindObject(mjOBJ_MESH, std::string(name));
if (!mesh) {
return nullptr;
}
return &(static_cast<mjCMesh*>(mesh)->spec);
}
// set frame
void mjm_setFrame(mjElement dest, mjmFrame* frame) {
if (!frame) {