Hello,
Thank you for providing this very nice library. I have several versions of OpenCV on my computer (3.4.10, 4.3.0, 4.5.1). I want to force the CMake to use OpenCV 4.5.1. For that, I set the OpenCV_DIR to point to the place that OpenCVConfog.cmake exists, but the CMake finds the path related to the older OpenCV 3.4.10 version. I think it is because in your CMakeLists.txt you first check for find_package(OpenCV 3.3.1 QUIET ) and since it already finds version 3.4, it works with this older version. I changed the following part in your CMakeLists.txt
and now the CMake works perfectly. If you accept this solution, I can make a pull request and also add a version control at the end of the above code to have OpenCV >= 3.3.1.
Hello, Thank you for providing this very nice library. I have several versions of OpenCV on my computer (3.4.10, 4.3.0, 4.5.1). I want to force the CMake to use OpenCV 4.5.1. For that, I set the
OpenCV_DIR
to point to the place thatOpenCVConfog.cmake
exists, but the CMake finds the path related to the older OpenCV 3.4.10 version. I think it is because in yourCMakeLists.txt
you first check forfind_package(OpenCV 3.3.1 QUIET )
and since it already finds version 3.4, it works with this older version. I changed the following part in yourCMakeLists.txt
to
and now the CMake works perfectly. If you accept this solution, I can make a pull request and also add a version control at the end of the above code to have
OpenCV >= 3.3.1
.