Ask Your Question
2

How to install opencv 4.1 using CMake and Visual Studio 2013?

asked 2019-04-24 09:54:48 -0600

FurxDev gravatar image

Hi,

I am trying to install OpenCV 4.1 using CMake with Visual Studio 2013 in 64 bits. I use this tutorial https://docs.opencv.org/3.4/d3/d52/tu... to install OpenCV 4.1. I installed previously: - Anaconda3 - Python2 - Visual Studio 2013 - Cmake 3.13.4 - Git 2.13.1

I chose the compiler : Visual Studio 12 2013 Win64.

Then, when I build in Visual Studio in Debug I have the following errors:

Error 1 error C2864: 'cv::sfinae::has_parenthesis_operator<c,ret,args...&gt;::value' :="" a="" static="" data="" member="" with="" an="" in-class="" initializer="" must="" have="" non-volatile="" const="" integral="" type="" d:\programmes\opencv4\opencv\modules\core\include\opencv2\core\cvstd_wrapper.hpp="" 52="" 1="" opencv_core_sse4_2="" error="" 2="" error="" c2864:="" 'cv::sfinae::has_parenthesis_operator<c,ret,args...&gt;::value'="" :="" a="" static="" data="" member="" with="" an="" in-class="" initializer="" must="" have="" non-volatile="" const="" integral="" type="" d:\programmes\opencv4\opencv\modules\core\include\opencv2\core\cvstd_wrapper.hpp="" 52="" 1="" opencv_core_sse4_1="" error="" 3="" error="" c2864:="" 'cv::sfinae::has_parenthesis_operator<c,ret,args...&gt;::value'="" :="" a="" static="" data="" member="" with="" an="" in-class="" initializer="" must="" have="" non-volatile="" const="" integral="" type="" d:\programmes\opencv4\opencv\modules\core\include\opencv2\core\cvstd_wrapper.hpp="" 52="" 1="" opencv_core_avx="" error="" 4="" error="" c2864:="" 'cv::sfinae::has_parenthesis_operator<c,ret,args...&gt;::value'="" :="" a="" static="" data="" member="" with="" an="" in-class="" initializer="" must="" have="" non-volatile="" const="" integral="" type="" (d:\programmes\opencv4\opencv\build\x64\vc12\modules\core\convert_scale.avx2.cpp)="" d:\programmes\opencv4\opencv\modules\core\include\opencv2\core\cvstd_wrapper.hpp="" 52="" 1="" opencv_core_avx2="" error="" 5="" error="" c2864:="" 'cv::sfinae::has_parenthesis_operator<c,ret,args...&gt;::value'="" :="" a="" static="" data="" member="" with="" an="" in-class="" initializer="" must="" have="" non-volatile="" const="" integral="" type="" (d:\programmes\opencv4\opencv\build\x64\vc12\modules\core\stat.avx2.cpp)="" d:\programmes\opencv4\opencv\modules\core\include\opencv2\core\cvstd_wrapper.hpp="" 52="" 1="" opencv_core_avx2="" error="" 6="" error="" c2864:="" 'cv::sfinae::has_parenthesis_operator<c,ret,args...&gt;::value'="" :="" a="" static="" data="" member="" with="" an="" in-class="" initializer="" must="" have="" non-volatile="" const="" integral="" type="" (d:\programmes\opencv4\opencv\build\x64\vc12\modules\core\mathfuncs_core.avx2.cpp)="" d:\programmes\opencv4\opencv\modules\core\include\opencv2\core\cvstd_wrapper.hpp="" 52="" 1="" opencv_core_avx2="" error="" 7="" error="" c2864:="" 'cv::sfinae::has_parenthesis_operator<c,ret,args...&gt;::value'="" :="" a="" static="" data="" member="" with="" an="" in-class="" initializer="" must="" have="" non-volatile="" const="" integral="" type="" (d:\programmes\opencv4\opencv\build\x64\vc12\modules\core\count_non_zero.avx2.cpp)="" d:\programmes\opencv4\opencv\modules\core\include\opencv2\core\cvstd_wrapper.hpp="" 52="" 1="" opencv_core_avx2="" error="" 8="" error="" c2864:="" 'cv::sfinae::has_parenthesis_operator<c,ret,args...&gt;::value'="" :="" a="" static="" data="" member="" with="" an="" in-class="" initializer="" must="" have="" non-volatile="" const="" integral="" type="" (d:\programmes\opencv4\opencv\build\x64\vc12\modules\core\convert.avx2.cpp)="" d:\programmes\opencv4\opencv\modules\core\include\opencv2\core\cvstd_wrapper.hpp="" 52="" 1="" opencv_core_avx2="" error="" 9="" error="" c2864:="" 'cv::sfinae::has_parenthesis_operator<c,ret,args...&gt;::value'="" :="" a="" static="" data="" member="" with="" an="" in-class="" initializer="" must="" have="" non-volatile="" const="" integral="" type="" (d:\programmes\opencv4\opencv\build\x64\vc12\modules\core\mean.avx2.cpp)="" d:\programmes\opencv4\opencv\modules\core\include\opencv2\core\cvstd_wrapper.hpp="" 52="" 1="" opencv_core_avx2="" error="" 10 ... (more)

edit retag flag offensive close merge delete

Comments

OpenCV 4 isn't compatible with visual studio 2013, I'm in the same boat.

Cubimon gravatar imageCubimon ( 2019-07-19 06:10:01 -0600 )edit

Can some answer this? really is this not compatible for VS2013?

Gilad Darmon gravatar imageGilad Darmon ( 2019-10-17 17:48:32 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2019-11-02 17:24:36 -0600

Gilad Darmon gravatar image

The answer for this is simple but takes a lot of effort to understand it for me. Visual Studio 2013 doesn't support all of c++11 features. which means some are supported and some aren't.

Here is a full list of what is supported for each Visual studio version 2013/2015/2017 https://docs.microsoft.com/en-us/prev...

OpenCV4.0.0 needs the support of many c++11 features that doens't exists in visual studio 2013, for OpenCV and for many of it's 3rd party libraries.

So no you can't compile OpenCV4.0.0 and above in Visual Studio 2013. I even tried to make some of the code backward compatible, but this is a huge effort, I guess it is time to move on and upgrade everything.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2019-04-24 09:54:48 -0600

Seen: 2,161 times

Last updated: Nov 02 '19