Write video frames and audio samples to multimedia file
Computer Vision Toolbox / Sinks
The To Multimedia File block writes video frames, audio samples, or both to
a multimedia (.avi
, .wav
, .mj2
,
.mp4
, or .m4v
) file.
You can compress the video frames or audio samples by selecting a compression algorithm. You can also control the type of video and/or audio in addition to other related properties the multimedia file receives.
Note
This block supports code generation for platforms that have file I/O available. You cannot use this block with Simulink® Desktop Real-Time™ software, because that product does not support file I/O.
This block performs best on platforms with Version 11 or later of Windows Media® Player software. This block supports only uncompressed RGB24 AVI files on Linux® and Mac platforms.
The generated code for this block relies on prebuilt library files. You can run this code
outside the MATLAB® environment, or redeploy it, but be sure to account for these extra library
files when doing so. The packNGo
function creates a single zip file
containing all of the pieces required to run or rebuild this code. See packNGo
(Simulink Coder) for more information.
To run an executable file that was generated from a model containing this block, you may need to add precompiled shared library files to your system path. See Simulink Coder, Simulink Shared Library Dependencies, and Accelerating Simulink Models for details.