I have made a Desktop application that has a live video stream, using C++. I use openCV’s VideoCapture.open() to open and run the stream on the application. It runs perfectly on debug and release mode on my system. Even after I package the application for deployment, and run the packaged application on my system, it runs perfectly.
However, when I try to run this packaged application on another PC, the application starts, but the stream is unable to open. Basically, the .open() function of VideoCapture returns false.
…Wrong. It would have found the files elsewhere. You don’t mention how you package the application and for what kind of deployment under what OS, but automatic file collectors are often not perfect and miss some dependencies.
@matti.vuori
It is a Qt application written in C++. I packaged it using Qt’s windeployqt.exe application.
Yes, it was not perfect and couldn’t run the application even on my own laptop initially (It showed pop-ups regarding missing dlls). But after I manually added all those missing dll, it worked perfectly on my laptop.
But somehow still not working on another machine.
As @berak suggested, I added the opencv_ffmpegxxxx.dll file to the package as well, and tried, but still got the same result.
I am using Windows. It is just a folder with the executable of the application, and all the dependencies/dll present along with it.
@berak@matti.vuori
I found the problem. The dll that was missing was opencv_videoio_ffmpegxxx.dll.
When I added this to the folder with the executable, it worked.
Thanks for your help.