Main Content


Converts Simulink data types to OpenCV data types

  • Library:
  • Computer Vision Toolbox Interface for OpenCV in Simulink


The ToOpenCV block converts the Simulink® data types to Simulink OpenCV data types.



expand all

Input signal to the ToOpenCV block. The input can be of different data types. Each of the input data types determines the output data type of the block.

Data Types: uint8 | uint16 | int8 | int16 | int32 | single | double | Simulink.ImageType | CV_DMATCH_BUS | CV_RECT_BUS | CV_ROTATEDRECT_BUS | CV_TERMCRITERIA_BUS | CV_SIZE_BUS | CV_RANGE_BUS | CV_POINT2I_BUS | CV_POINT2F_BUS | CV_POINT2D_BUS | CV_POINT3I_BUS | CV_POINT3F_BUS | CV_POINT3D_BUS


expand all

Output signal from the ToOpenCV block. The output signal supports OpenCV types. For more information, see Mapping Input and Output Data Types.

Data Types: OpenCV types


expand all

Specifies the input data type of the ToOpenCV block. The table lists the one-to-one mapping of the input versus output data types of the ToOpenCV block.

Programmatic Use

Block Parameter: DataType
Type: character vector
Value: input data type
Default: 'Point2i'

Block Characteristics

Data Types

Direct Feedthrough


Multidimensional Signals


Variable-Size Signals


More About

expand all

Extended Capabilities

Introduced in R2020a