smwritevideo
Configure and create multibody animation videos
Description
smwritevideo(
creates a video from the visualization of a multibody model.
modelIdentifier
,videoName
)modelIdentifier
is the source model name or handle.
videoName
is the generated video file name and path. You
can open the video file with any compatible media player.
The video properties are those specified in the Video Creator interface the moment you run the function. If the Video Creator parameters are in their default settings, the video properties are set to those defaults.
Before running smwritevideo
, you must simulate the model. In addition,
the model visualization results must open in a Multibody
Explorer window. If you have previously disabled model visualization,
reenable it before continuing. To do this, see Enable Multibody Explorer.
By default, if the model visualization pane is split into tiles, the function captures only
the active tile. A colored outline identifies the active tile. You can click a tile
to make it the active tile—or use the tile
name-value pair
argument to specify the number of the tile to record.
smwritevideo(
adds options for specifying the video properties. Use the
modelIdentifier
,videoName
,Name,Value
)Name,Value
pair arguments to set the visualization tile to
record, the video file format, the frame refresh rate, the frame width and height,
and the playback speed ratio. Unused arguments are set to the latest settings
specified in the Video Creator tool.
Examples
Input Arguments
Name-Value Arguments
Limitations
By default, on Linux distributions, the
smwritevideo
does not support the MPEG-4 format.
Version History
Introduced in R2016b