Недавно стал изучать visual studio 10 И тут же напарываюсь на непонятные ситуации.
Если не сложно направите меня на нужное направление.
Спасибо!
1>------ Build started: Project: new, Configuration: Debug Win32 ------
1> new.cpp
1>c:\users\администратор\documents\visual studio 2010\projects\new\new\new.cpp(8): error C2653: 'cv' : is not a class or namespace name
1>c:\users\администратор\documents\visual studio 2010\projects\new\new\new.cpp(8): error C2065: 'Mat' : undeclared identifier
1>c:\users\администратор\documents\visual studio 2010\projects\new\new\new.cpp(8): error C2146: syntax error : missing ';' before identifier 'img'
1>c:\users\администратор\documents\visual studio 2010\projects\new\new\new.cpp(8): error C2065: 'img' : undeclared identifier
1>c:\users\администратор\documents\visual studio 2010\projects\new\new\new.cpp(8): error C2653: 'cv' : is not a class or namespace name
1>c:\users\администратор\documents\visual studio 2010\projects\new\new\new.cpp(8): error C3861: 'imread': identifier not found
1>c:\users\администратор\documents\visual studio 2010\projects\new\new\new.cpp(9): error C2653: 'cv' : is not a class or namespace name
1>c:\users\администратор\documents\visual studio 2010\projects\new\new\new.cpp(9): error C2065: 'img' : undeclared identifier
1>c:\users\администратор\documents\visual studio 2010\projects\new\new\new.cpp(9): error C3861: 'imshow': identifier not found
1>c:\users\администратор\documents\visual studio 2010\projects\new\new\new.cpp(10): error C2653: 'cv' : is not a class or namespace name
1>c:\users\администратор\documents\visual studio 2010\projects\new\new\new.cpp(10): error C3861: 'waitKey': identifier not found
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Вот как выглядит в visual studio:
#include "stdafx.h"
int main()
{
cv::Mat img = cv::imread("cat.jpg");
cv::imshow("img", img);
cv::waitKey(0);
return 0;
}