- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
hi,
Im using "OpenCV Beta5" and "Matab 7.0.4" on windows.
I have installed OpenCV(with the exe) and now want to load this library in Matlab with the help of the following function of matlab
loadlibrary('cv097', 'H: empInstallOpenCVcvincludecv.h')
Im using "OpenCV Beta5" and "Matab 7.0.4" on windows.
I have installed OpenCV(with the exe) and now want to load this library in Matlab with the help of the following function of matlab
loadlibrary('cv097', 'H: empInstallOpenCVcvincludecv.h')
i got the following error
??? Error using ==> loadlibrary
Failed to preprocess the input file.
Output from preprocessor is:'C:Program' is not recognized as an internal or external command,
operable program or batch file.
Failed to preprocess the input file.
Output from preprocessor is:'C:Program' is not recognized as an internal or external command,
operable program or batch file.
would you explain what is the problem with my above code and how can i load the OpenCV in matlab ?
Thanks in advance
Link Copied
2 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
you need to check parameters you pass to loadlibrary with your Matlab documentation. Probably you specify something in wrong way.
Regards,
Vladimir
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I am trying to do the same thing, did you ever get it to work & if so, how did you do it?
This is what I have done:
addpath('C:Program FilesOpenCVcxcoreinclude');
addpath('C:Program FilesOpenCVcvauxinclude');
addpath('C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVincxts001.dll','C:Program FilesOpenCVall_includescxtypes.h','includepath','C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVin rs.dll','C:Program FilesOpenCVall_includescxtypes.h','includepath','C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVinlibguide40.dll','C:Program FilesOpenCVall_includescvcompat.h','includepath','C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVincxcore097.dll','C:Program FilesOpenCVall_includescxcore.h','includepath','C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVincv097.dll','C:Program FilesOpenCVall_includescv.h','includepath','C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVincvaux097.dll','C:Program FilesOpenCVall_includescvaux.h','includepath','C:Program FilesOpenCVall_includes');
%Read in an image
im=imread('seqsnap_00.bmp');
%create a IPL wrapper around the image passed from the workspace
v=libstruct('CvSize');
v.width=size(im,2);
v.height=size(im,1);
im1Ptr=calllib('cxcore097','cvCreateImageHeader',v,8,1);
I am still trying to figure out how to attach the image data to the Image Header using cvSetData.
Regards,
Martin.
I am trying to do the same thing, did you ever get it to work & if so, how did you do it?
This is what I have done:
addpath('C:Program FilesOpenCVcxcoreinclude');
addpath('C:Program FilesOpenCVcvauxinclude');
addpath('C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVincxts001.dll','C:Program FilesOpenCVall_includescxtypes.h','includepath','C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVin rs.dll','C:Program FilesOpenCVall_includescxtypes.h','includepath','C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVinlibguide40.dll','C:Program FilesOpenCVall_includescvcompat.h','includepath','C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVincxcore097.dll','C:Program FilesOpenCVall_includescxcore.h','includepath','C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVincv097.dll','C:Program FilesOpenCVall_includescv.h','includepath','C:Program FilesOpenCVall_includes');
loadlibrary('C:Program FilesOpenCVincvaux097.dll','C:Program FilesOpenCVall_includescvaux.h','includepath','C:Program FilesOpenCVall_includes');
%Read in an image
im=imread('seqsnap_00.bmp');
%create a IPL wrapper around the image passed from the workspace
v=libstruct('CvSize');
v.width=size(im,2);
v.height=size(im,1);
im1Ptr=calllib('cxcore097','cvCreateImageHeader',v,8,1);
I am still trying to figure out how to attach the image data to the Image Header using cvSetData.
Regards,
Martin.
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page