Miscellaneous linting in src/engine.

PiperOrigin-RevId: 462415459
Change-Id: I6c79c592613c6b0a665af06faf945586bb6ba32d
This commit is contained in:
Saran Tunyasuvunakool
2022-07-21 10:16:08 -07:00
committed by Copybara-Service
parent eef473b1e1
commit b849023069
19 changed files with 329 additions and 416 deletions
+2 -3
View File
@@ -34,7 +34,6 @@
// table of pair-wise collision functions
mjfCollision mjCOLLISIONFUNC[mjNGEOMTYPES][mjNGEOMTYPES] = {
/* PLANE HFIELD SPHERE CAPSULE ELLIPSOID CYLINDER BOX MESH */
/*PLANE */ {0, 0, mjc_PlaneSphere, mjc_PlaneCapsule, mjc_PlaneConvex, mjc_PlaneCylinder, mjc_PlaneBox, mjc_PlaneConvex},
/*HFIELD */ {0, 0, mjc_ConvexHField, mjc_ConvexHField, mjc_ConvexHField, mjc_ConvexHField, mjc_ConvexHField, mjc_ConvexHField},
@@ -44,7 +43,6 @@ mjfCollision mjCOLLISIONFUNC[mjNGEOMTYPES][mjNGEOMTYPES] = {
/*CYLINDER */ {0, 0, 0, 0, 0, mjc_Convex, mjc_Convex, mjc_Convex},
/*BOX */ {0, 0, 0, 0, 0, 0, mjc_BoxBox, mjc_Convex},
/*MESH */ {0, 0, 0, 0, 0, 0, 0, mjc_Convex}
};
@@ -146,10 +144,11 @@ void mj_collision(const mjModel* m, mjData* d) {
}
// finish merging predefined pairs
if (npair && m->opt.collision==mjCOL_ALL)
if (npair && m->opt.collision==mjCOL_ALL) {
while (pairadr<npair) {
mj_collideGeoms(m, d, pairadr++, -1, 0, 0);
}
}
}
mjFREESTACK;