Ask Your Question

Revision history [back]

'value' : is not a member of 'cv::DataDepth<_Tp>'

Hi everyone, I'm using OpenCV 2.4.4 (built from source using CMake), Win 7 64-bit, VC++ 2010. I got above error when compiling this line of code:

cv::Point2f fTmp ;
cv::Point   iTmp ;

iTmp = fTmp.operator cv::Point_<cv::Point>() ;

This is what on the compiler output:

1>D:\OpenCV\Build\install\include\opencv2/core/core.hpp(453): error C2039: 'value' : is not a member of 'cv::DataDepth<_Tp>' 1> with 1> [ 1> _Tp=cv::Point 1> ] 1> D:\OpenCV\Build\install\include\opencv2/core/core.hpp(597) : see reference to class template instantiation 'cv::Matx<_Tp,m,n>' being compiled 1> with 1> [ 1> _Tp=cv::Point, 1> m=2, 1> n=1 1> ] 1> test.cpp(142) : see reference to class template instantiation 'cv::Vec<_Tp,cn>' being compiled 1> with 1> [ 1> _Tp=cv::Point, 1> cn=2 1> ] 1>D:\OpenCV\Build\install\include\opencv2/core/core.hpp(453): error C2065: 'value' : undeclared identifier 1>D:\OpenCV\Build\install\include\opencv2/core/core.hpp(600): error C2039: 'value' : is not a member of 'cv::DataDepth<_Tp>' 1> with 1> [ 1> _Tp=cv::Point 1> ] 1>D:\OpenCV\Build\install\include\opencv2/core/core.hpp(600): error C2065: 'value' : undeclared identifier 1> 1>Build FAILED.

I've searched google and this forum but there is no answer. Hope someone could help me with this. Thanks !