obj2mfile
Convert video input objects to MATLAB code
Description
obj2mfile(
converts the video input object obj,filename)obj into a MATLAB® code file with the name specified by filename. The
file contains the MATLAB code required to restore the object and set its properties.
obj can be a single video input object or an array of
objects.
The obj2mfile function simplifies the process of restoring an
object with specific property settings. obj2mfile also creates
and configures the video source object associated with the video input
object.
If the UserData property of the object is set, or if any of the
callback properties is set to a cell array or to a function handle,
obj2mfile writes the data stored in those properties to a
MAT-file. obj2mfile gives the MAT-file the same name as the
M-file, but uses the .mat filename extension.
obj2mfile creates the MAT-file in the same folder as the
M-file.
Note
obj2mfile does not store the values of read-only
properties. For example, if an object is saved with a
Logging property set to 'on', the
object is restored with a Logging property set to
'off' (the default value). Use the
propinfo function to determine if a property is
read-only.
obj2mfile(
converts obj,filename,syntax)obj to the equivalent MATLAB code where the syntax argument specifies how to
assign values to properties when restoring the object.
obj2mfile(___,
converts mode)obj to the equivalent MATLAB code where mode specifies which properties are
configured.
obj2mfile(___,
converts reuse)obj to the equivalent MATLAB code where the reuse argument specifies whether
restoration searches for a reusable video input object or creates a new one.
Examples
Input Arguments
Version History
Introduced before R2006a