(1) IplImage 转 Mat:
IplImage* image = cvLoadImage( "lena.jpg");
Mat mat=cvarrToMat(image);
(2)Mat转IplImage:
IplImage img = IplImage(mat);
(1) IplImage 转 Mat:
IplImage* image = cvLoadImage( "lena.jpg");
Mat mat=cvarrToMat(image);
(2)Mat转IplImage:
IplImage img = IplImage(mat);