Results 1 to 4 of 4

Thread: Read video with Qt and Opencv

  1. #1
    Join Date
    Oct 2013
    Posts
    4
    Qt products
    Qt5
    Platforms
    Windows

    Default Read video with Qt and Opencv

    Hello!

    I need load a video files with opencv.
    I used this programming in the main.cpp.

    VideoCapture capture("video2_alcorcon.avi");
    for(; {

    capture >> src;
    imshow("imagen", src);
    waitKey(10);
    }

    In file.pro I include:


    INCLUDEPATH += C:\\Users\\Amaia\\Desktop\\opencvmin\\install\\inc lude
    LIBS += -LC:\\Users\\Amaia\\Desktop\\opencvmin\\install\\li b \
    -lopencv_core240 \
    -lopencv_highgui240 \
    -lopencv_imgproc240 \
    -lopencv_features2d240 \
    -lopencv_calib3d240

    And in header too:


    #include <opencv/cv.h>
    #include <opencv2/core/core.hpp>
    #include <opencv2/highgui/highgui.hpp>
    #include <opencv2/imgproc/imgproc.hpp>

    using namespace cv; //opencv

    But, I have got an error (file upload). I'm looking for a solution but I haven´t got.

    Please help me. I need use opencv in my proyect.
    Attached Images Attached Images

  2. #2
    Join Date
    Sep 2011
    Posts
    1,241
    Thanks
    3
    Thanked 127 Times in 126 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Re: Read video with Qt and Opencv

    why don't you ask on an opencv forum?
    If you have a problem, CUT and PASTE your code. Do not retype or simplify it. Give a COMPLETE and COMPILABLE example of your problem. Otherwise we are all guessing the problem from a fabrication where relevant details are often missing.

  3. #3
    Join Date
    Oct 2013
    Posts
    4
    Qt products
    Qt5
    Platforms
    Windows

    Post Re: Read video with Qt and Opencv

    I don´t know where there are an opencv forum.
    The error occurs when running the application. the programming in this well because opencv visual basic works.
    Please, help me
    Thank you in anticipation.

  4. #4
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Read video with Qt and Opencv

    The problem is you are in a Qt forum asking a question that has nothing but the most tenuous link to Qt.

    If it compiles (it seems to) then the problem is at run time. The most likely issue is that the OpenCV libraries are not in the PATH and thus are not found.

    Here is the OpenCV forum to start in: http://answers.opencv.org/questions/

Similar Threads

  1. Replies: 18
    Last Post: 7th August 2015, 16:53
  2. Corrupted video with OpenCV reading
    By yoti13 in forum Qt Programming
    Replies: 1
    Last Post: 12th July 2013, 02:43
  3. read webcam with opencv
    By rodolfo.marques in forum Newbie
    Replies: 5
    Last Post: 1st July 2012, 09:30
  4. How to capture Video with OpenCV
    By CCDamon in forum Qt Programming
    Replies: 5
    Last Post: 17th June 2011, 15:18
  5. Qt Gui with OpenCV video and buttons
    By marcusbarnet in forum Qt Programming
    Replies: 3
    Last Post: 20th May 2011, 09:48

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.