Main Content

Bring Custom Image Filter Algorithms as Reusable Blocks in Simulink

This example shows how to bring in C code image filter algorithms using C Caller blocks in a reusable Simulink library.

In this example, three image filter blocks are C Caller blocks in a library model. Their dependent C code is specified in the library model custom code settings.

The image filter C functions are implemented using ''Row-major'' array layout. Library custom code settings have ''Default function array layout'' set accordingly to ''Row-major''.

These library image filter blocks can be reused by adding them to models.

model = 'slexCCallerExampleImageFilter';

As the simulation runs, the MATLAB Function block displays the filtered images.


slcc('clearCustomCodeModules'); % unload custom libs before delete slprj folder

See Also

Related Topics