mirror of
https://gitlab.com/libeigen/eigen.git
synced 2026-04-10 11:34:33 +08:00
Fix QuaternionBase::cast for quaternion map and wrapper.
This commit is contained in:
@@ -245,6 +245,14 @@ template<typename Scalar> void mapQuaternion(void){
|
||||
// is used to determine whether we can return a coeff by reference or not, which is not enough for Map<const ...>.
|
||||
//const MCQuaternionUA& cmcq3(mcq3);
|
||||
//VERIFY( &cmcq3.x() == &mcq3.x() );
|
||||
|
||||
// test cast
|
||||
{
|
||||
Quaternion<float> q1f = mq1.template cast<float>();
|
||||
VERIFY_IS_APPROX(q1f.template cast<Scalar>(),mq1);
|
||||
Quaternion<double> q1d = mq1.template cast<double>();
|
||||
VERIFY_IS_APPROX(q1d.template cast<Scalar>(),mq1);
|
||||
}
|
||||
}
|
||||
|
||||
template<typename Scalar> void quaternionAlignment(void){
|
||||
|
||||
Reference in New Issue
Block a user