Image Processing Reference
In-Depth Information
to compare the input image with a blurred version of the input image. If the input
image contains a lot of edges, i.e., is sharp, then the two images will be significantly
different. If they are similar it is likely that the input image was blurred in the first
place.
8.2
Detecting Changes in the Video
In many systems we are interested in detecting what has changed in the scene, i.e.,
a new object enters the scene or an object is moving in the scene. For such purposes
we can use image subtraction, see Chap. 4, to compare the current image with a
previous image. If they differ, the difference defines the object or movement we are
looking for. In the rest of this chapter we will elaborate on this idea and present an
approach for detecting changes in video data.
8.2.1 The Algorithm
The algorithm for detecting changes in a video sequence consists of five steps:
1. Save reference image
2. Capture current image
3. Perform image subtraction
4. Thresholding
5. Filter noise
The algorithm can be performed in two different ways depending on the goal and
assumptions. If the background in the scene can be assumed to be static then every
new object entering the scene can in theory be segmented by subtracting an im-
age of the background from the current image. This process is denoted background
subtraction and illustrated in Fig. 8.3 . The reference image of the background is
captured as the first image when the system commences.
The other way the algorithm can be performed is when the assumption of a static
background breaks down. For example if the light in the scene changes significantly,
then an incoming image will be very different from the background even though no
changes occurred in the scene. In such situations the reference image should be the
previous image. The rationale is that the background in two consecutive images from
a video sequence is probably very similar and the only difference is the new/moving
object, see Fig. 8.4 . Such methods are denoted image differencing .
The difference between the two ways the algorithm can be performed results in
two different types of reference image: either the first in a sequence or the previous
image. The remaining four steps in the algorithm are the same for the two algorithms
and performed for each new image in the video.
Step Three
In Step three of the algorithm the reference image and current image are subtracted.
Let us denote the reference image r(x,y) and the current image f(x,y) .There-
sulting image, g(x,y) , is then given as
Search WWH ::




Custom Search