acfr / snark

generic c++ libraries and utilities for robotics
Other
69 stars 41 forks source link

points-frame interpolate option and Euler angles #84

Open akas9185 opened 10 years ago

akas9185 commented 10 years ago

If a nav stream happens to be close to 180 degrees then the stream might jump between -pi and pi. In that case, interpolation produces weird results.

aquad commented 10 years ago

I'd recommend using Eigen's quaternion slerp function: http://eigen.tuxfamily.org/dox/classEigen_1_1QuaternionBase.html#aa29a81b780c3012d0fd126a4525781c2

vlaskine commented 10 years ago

a good point; you either can use quaternions, or manually check in the interpolation function whether yaw crosses pi or -pi