Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/mysql/57.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
OpenCV函数不再受支持?_Opencv_Identifier - Fatal编程技术网

OpenCV函数不再受支持?

OpenCV函数不再受支持?,opencv,identifier,Opencv,Identifier,我正在使用某人使用OpenCV的原始代码()。我遇到一些OpenCV对象找不到标识符,有些没有问题 例如: CvRect ROI = cvRect(x, y, w, h); cvSetImageROI(bigImg, ROI); cvCopyImage(byteImg, bigImg); //For example here only this function is making problems cvResetImageROI(bigImg); cvReleaseImage(&b

我正在使用某人使用OpenCV的原始代码()。我遇到一些OpenCV对象找不到标识符,有些没有问题

例如:

CvRect ROI = cvRect(x, y, w, h);
cvSetImageROI(bigImg, ROI);
cvCopyImage(byteImg, bigImg);   //For example here only this function is making problems
cvResetImageROI(bigImg);
cvReleaseImage(&byteImg);
这是因为OpenCV版本不同吗

生成输出:

1>------ Build started: Project: OnlineFaceRec, Configuration: Debug Win32 ------
1>Build started 04.04.2014 21:47:28.
1>InitializeBuildStatus:
1>  Creating "Debug\OnlineFaceRec.unsuccessfulbuild" because "AlwaysCreate" was specified.
1>ClCompile:
1>  OnlineFaceRec.cpp
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(220): error C3861: 'cvCopyImage': identifier not found
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(255): error C3861: 'cvEigenDecomposite': identifier not found
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(308): error C2065: 'fileStorafge' : undeclared identifier
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(402): warning C4244: '=' : conversion from 'double' to 'float', possible loss of data
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(440): error C2065: 'CV_EIGOBJ_NO_CALLBACK' : undeclared identifier
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(436): error C3861: 'cvCalcEigenObjects': identifier not found
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(554): error C3861: 'cvEigenDecomposite': identifier not found
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(605): error C3861: 'Sleep': identifier not found
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(631): error C3861: 'cvCvtColor': identifier not found
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(660): error C3861: 'cvResize': identifier not found
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(665): error C3861: 'cvResize': identifier not found
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(763): error C3861: 'cvCvtColor': identifier not found
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(843): error C2065: 'FALSE' : undeclared identifier
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(849): error C2065: 'FALSE' : undeclared identifier
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(909): error C2065: 'VK_ESCAPE' : undeclared identifier
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(936): error C2065: 'TRUE' : undeclared identifier
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(943): error C2065: 'FALSE' : undeclared identifier
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(962): error C2065: 'FALSE' : undeclared identifier
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(996): error C3861: 'cvEqualizeHist': identifier not found
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(1006): error C3861: 'cvEigenDecomposite': identifier not found
1>c:\users\faraz\desktop\onlinefacerec\onlinefacerec.cpp(1062): error C2065: 'VK_ESCAPE' : undeclared identifier
1>
1>Build FAILED.
1>
1>Time Elapsed 00:00:02.52
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

嗯,shervin很棒,但是代码有点旧了

OpenCV API同时移动到C++,它现在已经有了正确的外观识别,并且在代码中隐藏了一些“Win32特殊”函数。 也许你想看看这里:

对于一个稍微新鲜的版本