From a3fad2e3c30d69555a1c7d75c3a7c8a336b22888 Mon Sep 17 00:00:00 2001 From: Benoit Jacob Date: Fri, 19 Dec 2008 15:55:35 +0000 Subject: [PATCH] Transform*Transform should return Transform unit test compiles again --- Eigen/src/Geometry/Transform.h | 4 ++-- test/geometry.cpp | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Eigen/src/Geometry/Transform.h b/Eigen/src/Geometry/Transform.h index f655ac1df..5d7f610cb 100644 --- a/Eigen/src/Geometry/Transform.h +++ b/Eigen/src/Geometry/Transform.h @@ -185,9 +185,9 @@ public: { return ei_transform_product_impl::run(*this,other.derived()); } /** Contatenates two transformations */ - inline const typename ProductReturnType::Type + inline const Transform operator * (const Transform& other) const - { return m_matrix * other.matrix(); } + { return Transform(m_matrix * other.matrix()); } /** \sa MatrixBase::setIdentity() */ void setIdentity() { m_matrix.setIdentity(); } diff --git a/test/geometry.cpp b/test/geometry.cpp index 9572535d7..eb5301055 100644 --- a/test/geometry.cpp +++ b/test/geometry.cpp @@ -186,7 +186,7 @@ template void geometry(void) Transform3 t4; t4 = aa3; VERIFY_IS_APPROX(t3.matrix(), t4.matrix()); - t4.rotate(AngleAxisx(-a,v3)); + t4.rotate(AngleAxisx(-a3,v3)); VERIFY_IS_APPROX(t4.matrix(), Matrix4::Identity()); v3 = Vector3::Random(); @@ -222,7 +222,7 @@ template void geometry(void) t21.setIdentity(); t21.linear() = Rotation2D(-a).toRotationMatrix(); VERIFY( (t20.fromPositionOrientationScale(v20,a,v21) - * (t21.prescale(v21.cwise().inverse()).translate(-v20))).isIdentity(test_precision()) ); + * (t21.prescale(v21.cwise().inverse()).translate(-v20))).matrix().isIdentity(test_precision()) ); // Transform - new API // 3D