遇到的error记录:使用cmake编译opencv报错

使用cmake编译opencv(包含了opencv_contrib),执行cmake命令时报错:

error: (-213:The function/feature is not implemented) This algorithm is patented and is excluded in this configuration; Set OPENCV_ENABLE_NONFREE CMake option and rebuild the library in function 'create'".

 

解决方法在:

https://answers.opencv.org/question/201938/how-can-i-set-opencv_enable_nonfree-cmake-option-and-rebuild-the-library-in-function-create/

cmake -DOPENCV_ENABLE_NONFREE:BOOL=ON -D CMAKE_INSTALL_PREFIX=/usr/local -D CMAKE_BUILD_TYPE=Release -D OPENCV_EXTRA_MODULES_PATH=../opencv_contrib/modules ..

(参数中路径要根据自己的机器更改一下啦)

 

 

你可能感兴趣的:(遇到的error记录:使用cmake编译opencv报错)