mexopencv

按照https://github.com/kyamagu/mexopencv

Linux

mkdir cmake_build

cd cmake_build

cmake ..

make

确认一下pkg-config命令可以识别opencv

pkg-config --cflags --libs opencv

进入mexopencv的地址,如果用matlab

make MATLABDIR=/opt/local/MATLAB/R2017a

addpath('/path/to/mexopencv');
addpath('/path/to/mexopencv/opencv_contrib');


% recommended
out = cv.filter2D(img, kern);  % with package name 'cv'


% not recommended
import cv.*;
out = filter2D(img, kern);     % no need to specify 'cv' after imported



你可能感兴趣的:(图像处理)