bizhen_npu
bizhen_npu
2016-04-07 01:03

在Qt5.3.1中opencv2.4.9配置的问题

5
  • opencv qt

(这是mainwindow.h里的内容,中间四个include包含的文件总是找不到)
#ifndef MAINWINDOW_H
#define MAINWINDOW_H

//#include
#include

#include
#include
#include
#include

//#include "cv.h"
//#include "cxcore.h"
//#include "highgui.h"
#include
#include
#include
using namespace std;
using namespace cv;
class MainWindow : public QMainWindow
{
……(后面不打了)

(这是pro文件里opencv的配置,我的opencv文件是放在c:\opencv文件夹里的,系统的环境变量自己也配了)
INCLUDEPATH+=c:\opencv\opencv\build\include\opencv\

c:\opencv\opencv\build\include\opencv2\

   c:\opencv\opencv\build\include\

LIBS+=c:\opencv\opencv\MinGW\lib\libopencv_calib3d249.dll.a\

c:\opencv\opencv\MinGW\lib\libopencv_contrib249.dll.a\

c:\opencv\opencv\MinGW\lib\libopencv_core249.dll.a\

c:\opencv\opencv\MinGW\lib\libopencv_features2d249.dll.a\

c:\opencv\opencv\MinGW\lib\libopencv_flann249.dll.a\

c:\opencv\opencv\MinGW\lib\libopencv_gpu249.dll.a\

c:\opencv\opencv\MinGW\lib\libopencv_highgui249.dll.a\

c:\opencv\opencv\MinGW\lib\libopencv_imgproc249.dll.a\

c:\opencv\opencv\MinGW\lib\libopencv_legacy249.dll.a\

c:\opencv\opencv\MinGW\lib\libopencv_ml249.dll.a\

c:\opencv\opencv\MinGW\lib\libopencv_objdetect249.dll.a\

c:\opencv\opencv\MinGW\lib\libopencv_video249.dll.a

  • 点赞
  • 回答
  • 收藏
  • 复制链接分享

2条回答