Main Content

To Simulink Image

Pack numeric matrix into a Simulink image

Since R2022a

Libraries:
Computer Vision Toolbox / Utilities

Description

The To Simulink Image block converts matrix data to Simulink® image data.

Examples

Ports

Input

expand all

Input signal to the To Simulink Image block. The input is a numerical matrix.

Data Types: integer | single | double | Boolean

Output

expand all

Output signal from the To Simulink Image block. The output is an image of Simulink.ImageType data type.

Data Types: Simulink.ImageType

Parameters

expand all

Specify the output data type of the image signal.

Click the Show data type assistant button to display the Data Type Assistant, which helps you set the data type attributes. For more information, see Specify Data Types Using Data Type Assistant (Simulink).

You can specify any of these options:

  • Inherited data type

  • Simulink image data type — Use the constructor for Simulink.ImageType object and specify the properties to describe the image. By default, the data type uses Simulink.ImageType(480,640,3) expression.

  • Custom data type — Use a MATLAB® expression that represents the rows, columns, and channels of the image respectively.

Programmatic Use

Block Parameter: OutDataTypeStr
Type: character vector
Value: Inherit: auto | Simulink.ImageType(480,640,3) | <data type expression>
Default: Inherit: auto

Block Characteristics

Data Types

double | single | integer | Boolean | image

Direct Feedthrough

yes

Multidimensional Signals

yes

Variable-Size Signals

no

Zero-Crossing Detection

no

Extended Capabilities

Version History

Introduced in R2022a