From 8511b69635ce10b4e94878f6fcf4cbc7303ae1e9 Mon Sep 17 00:00:00 2001 From: Vadim Pisarevsky Date: Sat, 11 Dec 2010 18:32:11 +0000 Subject: [PATCH] fixed Mat::Mat(Vec|Matx|vector) constructor (ticket #747) --- modules/core/include/opencv2/core/mat.hpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/modules/core/include/opencv2/core/mat.hpp b/modules/core/include/opencv2/core/mat.hpp index 367a61b793..f53d0a7827 100644 --- a/modules/core/include/opencv2/core/mat.hpp +++ b/modules/core/include/opencv2/core/mat.hpp @@ -805,7 +805,7 @@ template inline Mat_<_Tp>::Mat_(const Mat_& m, const Rect& roi) template template inline Mat_<_Tp>::Mat_(const Vec::channel_type, n>& vec, bool copyData) - : Mat(n/DataType<_Tp>::channels, 1, DataType<_Tp>::type, &vec) + : Mat(n/DataType<_Tp>::channels, 1, DataType<_Tp>::type, (void*)&vec) { CV_Assert(n%DataType<_Tp>::channels == 0); if( copyData ) @@ -814,7 +814,7 @@ template template inline template template inline Mat_<_Tp>::Mat_(const Matx::channel_type,m,n>& M, bool copyData) - : Mat(m, n/DataType<_Tp>::channels, DataType<_Tp>::type, &M) + : Mat(m, n/DataType<_Tp>::channels, DataType<_Tp>::type, (void*)&M) { CV_Assert(n % DataType<_Tp>::channels == 0); if( copyData ) @@ -822,7 +822,7 @@ template template inline } template inline Mat_<_Tp>::Mat_(const Point_::channel_type>& pt, bool copyData) - : Mat(2/DataType<_Tp>::channels, 1, DataType<_Tp>::type, &pt) + : Mat(2/DataType<_Tp>::channels, 1, DataType<_Tp>::type, (void*)&pt) { CV_Assert(2 % DataType<_Tp>::channels == 0); if( copyData ) @@ -830,7 +830,7 @@ template inline Mat_<_Tp>::Mat_(const Point_ inline Mat_<_Tp>::Mat_(const Point3_::channel_type>& pt, bool copyData) - : Mat(3/DataType<_Tp>::channels, 1, DataType<_Tp>::type, &pt) + : Mat(3/DataType<_Tp>::channels, 1, DataType<_Tp>::type, (void*)&pt) { CV_Assert(3 % DataType<_Tp>::channels == 0); if( copyData )