Delete remaining code related to now-removed distance equality constraint.

PiperOrigin-RevId: 513391064
Change-Id: I47fc344708a580c1e99bd2753113aaa408812966
This commit is contained in:
Yuval Tassa
2023-03-01 17:57:07 -08:00
committed by Copybara-Service
parent 50bebcb4ee
commit fd1070cf03
7 changed files with 12 additions and 59 deletions
-34
View File
@@ -468,7 +468,6 @@ void mjv_addGeoms(const mjModel* m, mjData* d, const mjvOption* vopt,
mjtNum *cur, *nxt, *xpos, *xfrc;
mjtNum vec[3], end[3], axis[3], rod, len, det, tmp[9], quat[4];
mjtByte broken;
mjContact *con;
mjvGeom* thisgeom;
mjvPerturb localpert;
float scl = m->stat.meansize, rgba[4];
@@ -1667,39 +1666,6 @@ void mjv_addGeoms(const mjModel* m, mjData* d, const mjvOption* vopt,
FINISH
}
}
// distance: find constraints at the end of the contact list
int j = d->ncon-1;
while (j>=0 && d->contact[j].exclude==3) {
// recover constraint id
int i = -d->contact[j].efc_address-2;
// segment = pos +/- normal*len
con = d->contact+j;
len = con->dist - m->eq_data[mjNEQDATA*i];
mju_addScl3(vec, con->pos, con->frame, 0.5*len);
mju_addScl3(end, con->pos, con->frame, -0.5*len);
// connect endpoints
START
// construct geom
sz[0] = scl * m->vis.scale.constraint;
mjv_makeConnector(thisgeom, mjGEOM_CAPSULE, sz[0],
vec[0], vec[1], vec[2],
end[0], end[1], end[2]);
f2f(thisgeom->rgba, m->vis.rgba.constraint, 4);
// vopt->label flag
if (vopt->label==mjLABEL_CONSTRAINT) {
makeLabel(m, mjOBJ_EQUALITY, i, thisgeom->label);
}
FINISH
j--;
}
}
// contact