Missing scalar type cast in Quaternion setFromTwoVectors()
Submitted by new..@..il.com
Assigned to Nobody
Link to original bugzilla bug (#806)
Version: 3.2
Description
In the function QuaternionBase<Derived>::setFromTwoVectors() (file Quaternion.h line 587), I think the scalar -1 in the code
c = max<Scalar>(c, -1);
should be casted to Scalar like the following
c = max<Scalar>(c, Scalar(-1));
as other scalars were done in the code.
This would be helpful for some scalar types like ceres::Jet. A compile error will occur if it is not casted.
Edited by Eigen Bugzilla