简体   繁体   中英

How to pack JavaCV / OpenCV in NetBeans?

I built a colour detecting program using JavaCV/OpenCV with Java on NetBeans and it runs well on my computer. I need to pack it in some way that I can open it on other machines without them having to install OpenCV themselves before. Is it possible?! If yes, how please?

I managed to import the Jar files but don't know what to do next.

Thanks loads, Antoinette

This is partially possible. You don't have to install the full openCV to make your code run on other machines but what you need are the dll files that you are actually using. In netbeans you should check what packages you are loading - eg if you use something like

import com.googlecode.javacv.cpp.opencv_core.*;
import com.googlecode.javacv.cpp.opencv_features2d.KeyPoint;

then you have to make sure that you have the opencv_core245.dll and the opencv_features2d245.dll (the numbers depend on the version of opencv) are on the machine running the code. You can find these depending on the architecture of the machine either in "opencv\\build\\x86\\vc10\\bin" or "opencv\\build\\x64\\vc10\\bin". Make sure that your path variable is pointing to the directory with these dlls.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM