I have the same problem and solved it this way. I assume that you downloaded a specific version from contrib repo according to the opencv version if you want to create it. So, go to the directory and enter, for example, the directory of the front module; in this directory there is a file called CMakeLists.txt that you must edit. This file should look like this:
set(the_description "Face recognition etc") ocv_define_module(face opencv_core opencv_imgproc opencv_objdetect WRAP python)
If you want to have the org.opencv.face package in your opencv-3xx.jar library, you need to change the second line of the file as follows:
ocv_define_module(face opencv_core opencv_imgproc opencv_objdetect WRAP python java)
Then you need to compile opencv as shown in Readme.md from the repo file https://github.com/itseez/opencv_contrib
Obviously, the same is true for all Contrib modules if you want to add opencv-3xx.jar to your library.
I hope this solution works for you, bye!
asdASD
source share