随笔分类 - opencv图像处理
摘要:// 5-2.cpp : 定义控制台应用程序的入口点。//#include "stdafx.h"#include<opencv/cv.h>#include<opencv/highgui.h>int _tmain(int argc, _TCHAR* argv[]){ IplImage* img=cvCreateImage(cvSize(200,200),IPL_DEPTH_8U,1); IplImage* dst1=cvCreateImage(cvSize(200,200),IPL_DEPTH_8U,1); IplImage* dst2=cvCreat
阅读全文
摘要:首先在项目属性-》配置属性-》链接器-》输入-》附加依赖项 中加入如下lib文件: opencv_imgproc220d.lib opencv_legacy220d.lib opencv_ml220d.lib opencv_core220d.lib opencv_highgui220d.lib opencv_video220d.lib// 4-4.cpp : 定义控制台应用程序的入口点。//#include "stdafx.h"#include<opencv/cv.h>#include<opencv/highgui.h>/*int g_switch_
阅读全文
摘要:// 4-3.cpp : 定义控制台应用程序的入口点。//#include "stdafx.h"#include<opencv/cv.h>#include<opencv/highgui.h>CvPoint begin,end;void my_mouse_callback( int event, int x, int y, int flags, void* param ); int main(){ IplImage* img=cvLoadImage("C:\\lena.jpg"); cvNamedWindow("DrawR
阅读全文
摘要:// 5-1.cpp : 定义控制台应用程序的入口点。//#include "stdafx.h"#include<opencv/cv.h>#include<opencv/highgui.h>int _tmain(){ IplImage* img=cvLoadImage("C:\\lena.jpg"); IplImage* dst1=cvCreateImage(cvGetSize(img),img->depth,img->nChannels); IplImage* dst2=cvCreateImage(cvGetSize
阅读全文
摘要:// 4-2.cpp : 定义控制台应用程序的入口点。//#include "stdafx.h"#include<opencv/cv.h>#include<opencv/highgui.h>int a,b;int showtext=0;void my_mouse_callback( int event, int x, int y, int flags, void* param );void mouseHandler( int event, int x, int y, int flags, void* param ); // A litte subro
阅读全文
摘要:#include "stdafx.h"#include <opencv/cv.h>#include <opencv/highgui.h>void main(){IplImage *img;IplImage *convert;img = cvLoadImage("C:\\lena.jpg",CV_LOAD_IMAGE_ANYCOLOR);convert=cvCreateImage( cvGetSize( img ), IPL_DEPTH_8U, 1);cvConvertImage(img,convert,CV_CVTIMG_FLIP
阅读全文
摘要:本人自己做的:#include "stdafx.h"#include<opencv/cv.h>#include<opencv/highgui.h>int main(){ //a.1从视频中趣图并显示。 CvCapture* capture = cvCreateFileCapture("C:\\test.avi"); IplImage* frame= cvQueryFrame( capture ); if( !frame ) return -1; cvNamedWindow("imagefromviedo", C
阅读全文

浙公网安备 33010602011771号