bytedeco / javacv

Java interface to OpenCV, FFmpeg, and more
Other
7.53k stars 1.58k forks source link

OpenCV manual instalation issue #1539

Open b005t3r opened 3 years ago

b005t3r commented 3 years ago

I'm using the jar files manually (because: reasons). With the previous version I had (1.4.x) it worked fine with having just OpenCV jars, but with the new one, after wasting some time, I figured out that I also needed OpenBLAS.

Why it's weird is because no unsatisfied link error is reported when not having OpenBLAS in the classpath, it simply freezes on first OpenCV call (in my case on new Mat()). There's no crash, no nothing. Probably a good idea to add some sanity checks for each module to report situations like this one.

saudet commented 3 years ago

FWIW, that's what tools like Gradle or Maven are for :)

b005t3r commented 3 years ago

The problem with this particular project and maven/gradle is there're a lot of unnecessary dependencies which you have to remove manually from your project's config and it is a pain (with all deps I think it's close to 1 GB), so for playing around that's an option, but to release something, cherry picking jars is actually a bit less painful :)

saudet commented 3 years ago

There are some tricks for that: https://github.com/bytedeco/javacpp-presets/wiki/Reducing-the-Number-of-Dependencies

saudet commented 3 years ago

It's particularly easy with Gradle JavaCPP: https://github.com/bytedeco/gradle-javacpp#the-platform-plugin