Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Using Opencv with QT
QtWS25 Last Chance

Using Opencv with QT

Scheduled Pinned Locked Moved General and Desktop
4 Posts 3 Posters 5.5k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • O Offline
    O Offline
    omi1990
    wrote on last edited by
    #1

    I have integrated opencv in qt .
    added all in .pro file also.
    qt can find library of cv but i m getting linker error on building it.
    @
    (?release@Mat@cv@@QAEXXZ)
    detection.obj : error LNK2019: unresolved external symbol "public: virtual __thiscall cv::VideoCapture::~VideoCapture(void)" (??1VideoCapture@cv@@UAE@XZ) referenced in function __unwindfunclet$?on_start_clicked@Detection@@AAEXXZ$0
    detection.obj : error LNK2019: unresolved external symbol "int __cdecl cv::waitKey(int)" (?waitKey@cv@@YAHH@Z) referenced in function "private: void __thiscall Detection::on_start_clicked(void)" (?on_start_clicked@Detection@@AAEXXZ)
    detection.obj : error LNK2019: unresolved external symbol "public: virtual bool __thiscall cv::VideoCapture::isOpened(void)const " (?isOpened@VideoCapture@cv@@UBE_NXZ) referenced in function "private: void __thiscall Detection::on_start_clicked(void)" (?on_start_clicked@Detection@@AAEXXZ)
    detection.obj : error LNK2019: unresolved external symbol "public: __thiscall cv::VideoCapture::VideoCapture(int)" (??0VideoCapture@cv@@QAE@H@Z) referenced in function "private: void __thiscall Detection::on_start_clicked(void)" (?on_start_clicked@Detection@@AAEXXZ)
    release\Detection.exe : fatal error LNK1120: 5 unresolved externals
    command failed with exit code 1120
    command failed with exit code 2
    The process "C:\Qt\qtcreator-2.3.1\bin\jom.exe" exited with code 2.
    Error while building project Detection (target: Desktop)
    When executing build step 'Make'
    @
    i am using opencv 2.0 and qt creator 2.3.1

    pls help me with this.

    1 Reply Last reply
    0
    • Q Offline
      Q Offline
      qxoz
      wrote on last edited by
      #2

      Can you post your .pro file?

      1 Reply Last reply
      0
      • O Offline
        O Offline
        omi1990
        wrote on last edited by
        #3

        #-------------------------------------------------

        Project created by QtCreator 2011-11-25T00:34:05

        #-------------------------------------------------

        QT += core gui

        TARGET = Detection
        TEMPLATE = app

        SOURCES += main.cpp
        detection.cpp

        HEADERS += detection.h

        FORMS += detection.ui
        INCLUDEPATH += C:\OpenCV2.0\include
        LIBS += -LC:\OpenCV2.0\lib
        -lopencv_core220
        -lopencv_highgui220
        -lopencv_imgproc220
        -lopencv_features2d220
        -lopencv_calib3d220

        1 Reply Last reply
        0
        • A Offline
          A Offline
          AnuruddhaH
          wrote on last edited by
          #4

          Use forward slashes in paths. \ is used as a separator for multiple entries.

          INCLUDEPATH += C:/OpenCV2.0/include

          LIBS += -LC:/OpenCV2.0/lib
          -lopencv_core220
          -lopencv_highgui220
          -lopencv_imgproc220
          -lopencv_features2d220
          -lopencv_calib3d220

          1 Reply Last reply
          0

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved