创建新项目
添加主函数文件
配置
添加环境变量
测试
#include <opencv2/opencv.hpp>
#include <iostream>
using namespace cv;
using namespace std;
int main()
{
Mat img = imread("C:\\Users\\Pictures\\test.jpg");
if (img.empty())
{
printf("Could not find the image!\n");
return -1;
}
imshow("ImputImage", img);
waitKey(0);
return 0;
}