< SwisTrack < Components

Description

This component subtracts the background image from the input image. However, this subtraction is done in the HSV space, using only the first channel (Hue).

If the camera is fixed, only the objects added to the scene remain after this subtraction. However, lighting condition variations or the camera noise can also produce a difference between the two images. As we do the subtraction in the Hue channel, light intensity has nearly no influence on the result as we are comparing the color. However, if there is color like white, gray or black, the tracking is really bad as those color are not well defined in the hue band. A small change can make them go from the pure red to the pure blue. Moreover, destructive data compression like DivX modify the color on the border of the object a lot, as we can see in the example image used here.

Most of the time, a threshold is applied after this method, to separate the background from the tracked objects.

Input

A color image.

Output

A grayscale image.

Parameters

Background Image

Path to the background image file (color). The background image must be a picture of the arena without the object to track.

This article is issued from Wikibooks. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.