In a motion detection system, filters are applied to a series of digital
images in order to determine whether changes in the properties of pixels
between the current image and a reference model are due to motion of
objects or to changes in lighting. The filter may be based on scaled
differences between a current image and a reference model. The type of
surface may be determined based on optical properties of the surface and
then only the best filter for that type of surface is applied.
Alternately, multiple filters may all be applied and the results
combined. The processing may be reduced using a background model to
determine which pixels are in the background and which are in the
foreground and then only applying the filter to the foreground pixels.