From d37beb4074112f99432cfaacebbe29bd89f4937a Mon Sep 17 00:00:00 2001 From: Vadim Pisarevsky Date: Fri, 12 Aug 2011 12:54:38 +0000 Subject: [PATCH] fixed Matx33 * Point3 and Matx22 * Point operators (ticket #1299) --- modules/core/include/opencv2/core/operations.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/core/include/opencv2/core/operations.hpp b/modules/core/include/opencv2/core/operations.hpp index 1f1aca8393..ee37b706da 100644 --- a/modules/core/include/opencv2/core/operations.hpp +++ b/modules/core/include/opencv2/core/operations.hpp @@ -625,14 +625,14 @@ Matx<_Tp, m, n> operator * (const Matx<_Tp, m, l>& a, const Matx<_Tp, l, n>& b) template static inline Point_<_Tp> operator * (const Matx<_Tp, 2, 2>& a, const Point_<_Tp>& b) { - return Point_<_Tp>(a*Vec<_Tp,2>(b)); + return Point_<_Tp>(a*Vec<_Tp,2>(b.x,b.y)); } template static inline Point3_<_Tp> operator * (const Matx<_Tp, 3, 3>& a, const Point3_<_Tp>& b) { - return Point3_<_Tp>(a*Vec<_Tp,3>(b)); + return Point3_<_Tp>(a*Vec<_Tp,3>(b.x,b.y,b.z)); } @@ -653,7 +653,7 @@ Matx<_Tp, 4, 1> operator * (const Matx<_Tp, 4, 4>& a, const Point3_<_Tp>& b) template static inline Scalar operator * (const Matx<_Tp, 4, 4>& a, const Scalar& b) { - return Scalar(a*Matx<_Tp, 4, 1>(b)); + return Scalar(a*Matx<_Tp, 4, 1>(b[0],b[1],b[2],b[3])); }