Reputation: 31
I downloaded opencv-2.4.9.exe
and I opened it D:\opencv
directory.
After that I wrote an OpenCV library with Visual Studio 2013 and also a wrapper DLL. I used this wrapper DLL in a C# Windows application. It worked perfectly on my computer. But when I copy and run it on another computer, it gives me an error. The error says that it cannot find the OpenCV DLLs.
Here are the sources that I used:
How can I make my program run on any computer even if OpenCV doesn't exist?
Upvotes: 3
Views: 1064
Reputation: 1918
When you make your DLL wrapper you can do it two ways: You can choose to link against the OpenCV DLLs or to compile OpenCV as a static library into your DLL. Presumably you are currently linking against the OpenCV DLLs, which means that your DLL wrapper is looking for the OpenCV DLLs when it gets loaded so that it can execute code from those DLLs. If you have OpenCV installed on your system it is possible that you have the OpenCV DLLs in your OS' Path and therefore it can find the OpenCV DLLs on your computer. When you go to another computer this may fail. You have two options.
Upvotes: 1