From 6d223fcd925bb1f04d132ff606e4be2edba853b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20M=C3=B6bius?= <moebius@cs.rwth-aachen.de> Date: Mon, 2 Sep 2019 12:30:42 +0200 Subject: [PATCH] Revert "Merge branch 'mat3x3-mixed-mult' into 'master'" This reverts merge request !162 --- libs_required/ACG/Math/Matrix3x3T.hh | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/libs_required/ACG/Math/Matrix3x3T.hh b/libs_required/ACG/Math/Matrix3x3T.hh index faf66c01..1f170387 100644 --- a/libs_required/ACG/Math/Matrix3x3T.hh +++ b/libs_required/ACG/Math/Matrix3x3T.hh @@ -128,26 +128,20 @@ class Matrix3x3T { }}; } - template<typename OtherScalar> - constexpr auto operator*(const VectorT<OtherScalar,3> &rhs) const - -> OpenMesh::VectorT<decltype((*this)(0,0) * rhs[0]), 3> - { - return { + constexpr Vec3 operator*(const Vec3 &rhs) const { + return Vec3( (*this)(0, 0) * rhs[0] + (*this)(0, 1) * rhs[1] + (*this)(0, 2) * rhs[2], (*this)(1, 0) * rhs[0] + (*this)(1, 1) * rhs[1] + (*this)(1, 2) * rhs[2], (*this)(2, 0) * rhs[0] + (*this)(2, 1) * rhs[1] + (*this)(2, 2) * rhs[2] - }; + ); } - template<typename OtherScalar> - constexpr friend auto operator*(VectorT<OtherScalar,3> v, const Matrix3x3T &rhs) - -> OpenMesh::VectorT<decltype(rhs(0,0) * v[0]), 3> - { - return { + constexpr friend Vec3 operator*(Vec3 v, const Matrix3x3T &rhs) { + return Vec3( rhs(0, 0) * v[0] + rhs(0, 1) * v[1] + rhs(0, 2) * v[2], rhs(1, 0) * v[0] + rhs(1, 1) * v[1] + rhs(1, 2) * v[2], rhs(2, 0) * v[0] + rhs(2, 1) * v[1] + rhs(2, 2) * v[2] - }; + ); } constexpr Matrix3x3T operator*(Scalar c) const { -- GitLab