[sharedmemory] Fill-out calculateJacobian command.

The server command processor actually didn't do anything with
the local point that was passed along with the calculateJacobian
command. Added in the necessary bit of math to return the
corresponding jacobian.

Also, fixed a typo in pybullet that was returning the same
jacobian for translation and rotation.
This commit is contained in:
Jeffrey Bingham
2017-09-24 14:14:24 -07:00
parent 8eb69552d1
commit ee30ca93c5
4 changed files with 47 additions and 2 deletions

View File

@@ -33,6 +33,18 @@ void setZero(mat33 &m) {
m(2, 2) = 0;
}
void skew(vec3& v, mat33* result) {
(*result)(0, 0) = 0.0;
(*result)(0, 1) = -v(2);
(*result)(0, 2) = v(1);
(*result)(1, 0) = v(2);
(*result)(1, 1) = 0.0;
(*result)(1, 2) = -v(0);
(*result)(2, 0) = -v(1);
(*result)(2, 1) = v(0);
(*result)(2, 2) = 0.0;
}
idScalar maxAbs(const vecx &v) {
idScalar result = 0.0;
for (int i = 0; i < v.size(); i++) {