From 7b2dd988faf589ce194002ffffdfa6efca656557 Mon Sep 17 00:00:00 2001 From: Hauke Heibel Date: Tue, 2 Feb 2010 09:27:41 +0100 Subject: Fixes #89. Added regression test. --- test/geo_transformations.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'test/geo_transformations.cpp') diff --git a/test/geo_transformations.cpp b/test/geo_transformations.cpp index fc542e71b..895fe0f08 100644 --- a/test/geo_transformations.cpp +++ b/test/geo_transformations.cpp @@ -85,6 +85,10 @@ template void transformations(void) VERIFY_IS_APPROX(q1 * v1, Quaternionx(aa) * v1); VERIFY_IS_NOT_APPROX(q1 * v1, Quaternionx(AngleAxisx(aa.angle()*2,aa.axis())) * v1); + aa.fromRotationMatrix(aa.toRotationMatrix()); + VERIFY_IS_APPROX(q1 * v1, Quaternionx(aa) * v1); + VERIFY_IS_NOT_APPROX(q1 * v1, Quaternionx(AngleAxisx(aa.angle()*2,aa.axis())) * v1); + // AngleAxis VERIFY_IS_APPROX(AngleAxisx(a,v1.normalized()).toRotationMatrix(), Quaternionx(AngleAxisx(a,v1.normalized())).toRotationMatrix()); -- cgit v1.2.3