Ask Your Question
0

Write mat files in visual studio

asked 2014-05-01 11:10:54 -0600

xcsa gravatar image

hello,

I use visual studio with openCV in c and c + +. I want to record the data of an image (gray scale) in a mat file (. Mat) and then read it in matlab. Try using the matio library, but it gives me errors.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2014-05-02 04:01:27 -0600

This should be quite simple

  1. Load in the image in openCV using VideoCapture for example from a camera
  2. Save it to a directory on the filesystem using the imwrite function of OpenCV
  3. Use the MATLAB imread function to read from the file system

OR you could store your matrix in an XML file using the FileStorage interface, then use matlab to browse through the XML data if you want it more complex.

edit flag offensive delete link more

Question Tools

Stats

Asked: 2014-05-01 11:10:54 -0600

Seen: 563 times

Last updated: May 02 '14