Interpolation of orientations is accomplished with spherical linear interpolation of quaternions (slerp). The usual approach is to invert one of the quaternions when cosine of the angle between them is less than zero.
Logged In: YES
Implemented fix based on patch from Mathieu Joubert, and verified that it fixes wild rotations seen with the SampledOrientation from the INTEGRAL add-on. Awaiting verification of the patch from Mathieu before closing this bug.
Fixed by modifying slerp. In the future, we may want to move the shortest path selection out of slerp into some higher level function, but this is low priority.