diff --git a/plugin/usd_decoder/usd_decoder.cc b/plugin/usd_decoder/usd_decoder.cc index 8d45bd5d..1392a1ca 100644 --- a/plugin/usd_decoder/usd_decoder.cc +++ b/plugin/usd_decoder/usd_decoder.cc @@ -1720,7 +1720,11 @@ void ParseUsdGeomGprim(mjSpec* spec, const pxr::UsdPrim& gprim, ParseDisplayColorAndOpacity(gprim, geom); SetLocalPoseFromPrim(gprim, body_prim, geom, caches.xform_cache); if (!MaybeParseGeomPrimitive(gprim, geom, caches.xform_cache)) { - ParseUsdMesh(spec, gprim, geom, caches.xform_cache); + mjsMesh* mesh = ParseUsdMesh(spec, gprim, geom, caches.xform_cache); + if (mesh != nullptr && gprim.HasAPI()) { + ParseMjcPhysicsMeshCollisionAPI(mesh, + pxr::MjcPhysicsMeshCollisionAPI(gprim)); + } } pxr::UsdShadeMaterial bound_material =