qt - Not able to access my webcam using opencv library -


i'm trying use webcam (in qt) using opencv library. error code:

#include "mainwindow.h" #include <qapplication> #include <qlabel> #include <opencv2/opencv.hpp> #include <opencv/cv.h> #include <qtwidgets> #include <qimage>  int main(int argc, char *argv[]) {    cv::videocapture camera;    camera.open(1); } 

saying

/home/darshan/aindradesktopapp/main.cpp:27: error: undefined reference  `cv::videocapture::videocapture()' /home/darshan/aindradesktopapp/main.cpp:28: error: undefined reference `cv::videocapture::open(int)' /home/darshan/aindradesktopapp/main.cpp:30: error: undefined reference `cv::videocapture::~videocapture()' /home/darshan/aindradesktopapp/main.cpp:30: error: undefined reference `cv::videocapture::~videocapture()' collect2: error: collect2: error: ld returned 1 exit status 

what should do?


Comments

Popular posts from this blog

c++ - Creating new partition disk winapi -

Android Prevent Bluetooth Pairing Dialog -

VBA function to include CDATA -