标签:cvconvertimage 彩色灰度转换 垂直旋转图像 opencv
核心函数:cvConvertImage
程序:
代码:
#include "cv.h" #include "cxcore.h" #include "highgui.h" #include <iostream> int ConvertImage(int argc,char** argv) { IplImage* src=cvLoadImage("e:\\picture\\4.jpg"); IplImage* dst=cvCreateImage(cvGetSize(src),8,1); cvConvertImage(src,dst,CV_CVTIMG_FLIP); //上下翻转加颜色变换 cvNamedWindow("src"); cvNamedWindow("dst"); cvShowImage("src",src); cvShowImage("dst",dst); cvWaitKey(0); cvDestroyWindow("src"); cvDestroyWindow("dst"); cvReleaseImage(&src); cvReleaseImage(&dst); return 0; }
本文出自 “flyclc” 博客,请务必保留此出处http://flyclc.blog.51cto.com/1385758/1539937
cvConvertImage 彩色灰度转换 垂直旋转图像,布布扣,bubuko.com
标签:cvconvertimage 彩色灰度转换 垂直旋转图像 opencv
原文地址:http://flyclc.blog.51cto.com/1385758/1539937