PDA

View Full Version : Error OpenCV capture image



Mien89
17th October 2012, 15:34
Hello everyone, I'm new to the forum. I'm doing a project on image processing which use the OpenCV 2.1 and Qt Creator 2.5.2.
The point is that the image processing program rezalize it in Dev C + + and it was great, but then when I go to Qt gives me an error that I have no idea where it comes from. The error is:

Starting C: \ Users \ Damian \ Desktop \ Testing
The program has unexpectedly finished.
C: \ Users \ Damian \ Desktop \ Testing QT \ Camara_Webcam-build-desktop-Qt_4_8_1_for_Desktop_-_MinGW__Qt_SDK__Debug \ debug \ Camara_Webcam.exe exited with code -1073741515

Could anyone help, or spend some example to capture images for laptop webcam?

A greeting.

ChrisW67
18th October 2012, 08:58
Camara_Webcam.exe exited with code -1073741515
-1073741515 == 0xC0000135 The application failed to initialize properly

The program is missing one or all of the libraries it depends on at runtime, probably one or all of the OpenCV libraries.

Mien89
18th October 2012, 11:52
My file .pro is called XCopter.pro and it is this:

#-------------------------------------------------
#
# Project created by QtCreator 2012-09-27T23:10:14
#
#-------------------------------------------------

QT += core gui

TARGET = XCopter
TEMPLATE = app


SOURCES += main.cpp\
mainwindow.cpp

HEADERS += mainwindow.h

FORMS += mainwindow.ui

RESOURCES += \
rscxcopter.qrc

LIBS += "C:/OpenCV2.1/lib/cv210.lib"
LIBS += "C:/OpenCV2.1/lib/cvaux210.lib"
LIBS += "C:/OpenCV2.1/lib/cxcore210.lib"
LIBS += "C:/OpenCV2.1/lib/highgui210.lib"
INCLUDEPATH += C:\OpenCV2.1\include\opencv
#-------------------------------------------------

I think all libraries are added, if not it is not like adding libraries. Could you help me?.

ChrisW67
18th October 2012, 22:21
Your problem is at run time not compile/link time. Your running program's environment does not allow the running program to find some component that it depends on. Components include the DLL files that are the run-time implementation of OpenCV. Since you are afflicted with Windows the libraries needed by the program need to be in one of these places:

The folder the executable is in
A folder on the PATH defined in the environment the program is running in
Installed in the Windows SxS store (e.g. the MSVC runtime) or a private assembly


Load your program into Dependency Walker (running in the failing environment) and see what comes up in red.