Ask Your Question
0

using Matlab module of opencv_contrib

asked 2015-10-31 10:56:19 -0600

Gio gravatar image

hello, I just cannot get the Matlab module of the opencv_contrib working at all;

I downloaded latest opencv and opencv_contrib, compiled properly with Visual Studio 2013 (everything is fine with Cmake: python is found, Matlab is enabled, and I get "Matlab: Compiler/generator: Working")

no errors in the compilation of the solution; I build the INSTALL and get the folder "matlab" in the install folder; open matlab, add the path with addpath; "help cv" works fine "cv.buildInformation" works fine

but any other function call fails;

e.g. img = cv.IMREAD_COLOR('d:/temp/Desert.png'); fails with: Index exceeds matrix dimensions.

or: camera=cv.VideoCapture();

or: there is no cv.dft as suggested in the help page of the Matlab module github page

what's wrong? any idea?

edit retag flag offensive close merge delete

Comments

bear with me, no idea about matlab, but cv.IMREAD_COLOR is supposed to be a constant, to be used like: cv.imread('d:/temp/Desert.png', cv.IMREAD_COLOR);

berak gravatar imageberak ( 2015-10-31 12:12:21 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
2

answered 2015-11-06 08:26:23 -0600

Gio gravatar image

thanks berak, your words turned on the key solution: the compilation was failing because... there was a space char in the folder name; after I removed it, compilation works and in matlab I have all functions; so, for people that use it under windows, remember that compilation suffers of spaces in the folder names;

I have now a question on the fact that the funcion helps (e.g. help cv.dft) doesn't work; I will write a new post for this;

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2015-10-31 10:56:19 -0600

Seen: 420 times

Last updated: Nov 06 '15