Main Content

Find Complement of Intensity Image

This example shows how to obtain the complement of an intensity image.

Example Model

Open the Simulink® model.

modelname = 'ex_blockImageComplement.slx';

The model reads an input intensity image using the Image From File block. The Image Complement block computes the complement of this image. The model displays the resulted output image using the Video Viewer block.

Simulate and Display Results

Run the model to visualize the output image. It can clearly be seen that the dark areas became lighter and the light areas became darker in the output image.