Ask Your Question

Revision history [back]

Error undefined variable "cv" - Matlab

System information (version)

OpenCV => 2.4.13 Operating System / Platform => Windows 10 64-Bit Compiler => Visual Studio 2012 Detailed description

I am trying to run a Matlab code using some OpenCV commands but I keep getting this error. What should I do? I already tried to install the OpenCV as in its guide following the 5 steps for Pre-built Libraries as follows but didn't work, I am probably missing or misunderstanding something. I would appreciate your help. Thank you guys in advance

http://docs.opencv.org/2.4/doc/tutorials/introduction/windows_install/windows_install.html#windows-installation

image description

image description

image description

Follows the Matlab error:

Undefined variable "cv" or class "cv.cvtColor".

Error in face_d_t_new (line 35) gr = cv.cvtColor(videoFrame, 'RGB2GRAY');

Error in HR (line 21) [pos, distance] = face_d_t_new(vid_name, fr, s);