#include <opencv2\opencv.hpp>
#include <iostream>
#include <string>
using namespace cv;
using namespace std;
int main()
{
Mat img = imread("lena.jpg");
if(img.empty()) { cout<<"error"; return -1; }
imshow("mypic",img);
waitKey();
return 0;
}版权声明:本文为博主原创文章,未经博主允许不得转载。
原文:http://blog.csdn.net/dopamy_busymonkey/article/details/46772575