Skip to Main Content Skip to Search
Product Documentation

Saving Image Acquisition Objects

Using the save Command

You can save a video input object to a MAT-file just as you would any workspace variable by using the save command. This example saves the video input object vid to the MAT-file myvid.mat.

save myvid vid

When you save a video input object, all the video source objects associated with the video input object are also saved.

To load an image acquisition object that was saved to a MAT-file into the MATLAB workspace, use the load command. For example, to load vid from MAT-file myvid.mat, use

load myvid

Using the obj2mfile Command

Another way to save a video input object is to create an M-file that contains the set of commands used to create the video input object and configure its properties. You can use the obj2mfile function to create such an M-file. When you execute the M-file, it can create a new video input object or reuses an existing video input object, if one exists that has the same video format and adaptor.

  


Recommended Products

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.

 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS