6/09/2016

OpenCV image and video write

image write


..
Mat img = imread("ss.jpg");
 vector< Mat> rgbMat(3);
 cv::split(img, rgbMat);

 namedWindow("img", 0); //make window
 imshow("img", rgbMat[2]); //show
 waitKey(0);

 imwrite("r.jpg", rgbMat[2]);
 imwrite("g.bmp", rgbMat[1]);
 imwrite("b.tif", rgbMat[0]);


...



video write
http://study.marearts.com/2013/09/opencv-video-writer-example-source-code.html

No comments:

Post a Comment