Information Technology Reference
In-Depth Information
Having encoded the I picture, attention turns to the P picture. The input sequence is IBBP , but the transmitted
sequence must be IPBB . Figure 5.35(c) shows that the reordering delay is bypassed to select the P picture. This
passes to the motion estimator which compares it with the I picture and outputs a vector for each macroblock. The
forward predictor uses these vectors to shift the I picture so that it more closely resembles the P picture. The
predicted picture is then subtracted from the actual picture to produce a forward prediction error. This is then
spatially coded. Thus the P picture is transmitted as a set of vectors and a prediction error image.
The P picture is locally decoded in the right-hand decoder. This takes the forward-predicted picture and adds the
decoded prediction error to obtain exactly what the decoder will obtain.
Figure 5.35(d) shows that the encoder now contains an I picture in the left store and a P picture in the right store.
The reordering delay is reselected so that the first B picture can be input. This passes to the motion estimator
where it is compared with both the I and P pictures to produce forward and backward vectors. The forward vectors
go to the forward predictor to make a B prediction from the I picture. The backward vectors go to the backward
predictor to make a B prediction from the P picture. These predictions are simultaneously subtracted from the
actual B picture to produce a forward prediction error and a backward prediction error. These are then spatially
encoded. The encoder can then decide which direction of coding resulted in the best prediction; i.e. the smallest
prediction error.
In the encoder shown, motion estimation sometimes takes place between an input picture and a decoded picture.
With increased complexity, the original input pictures may be stored for motion- estimation purposes. As these
contain no compression artifacts the motion vectors may be more accurate.
Not shown in the interests of clarity is a third signal path which creates a predicted B picture from the average of
forward and backward predictions. This is subtracted from the input picture to produce a third prediction error. In
some circumstances this prediction error may use fewer data than either forward of backward prediction alone.
As B pictures are never used to create other pictures, the decoder does not locally decode the B picture. After
decoding and displaying the B picture the decoder will discard it. At the encoder the I and P pictures remain in their
frame stores and the second B picture is input from the reordering delay.
Following the encoding of the second B picture, the encoder must reorder again to encode the second P picture in
the GOP. This will be locally decoded and will replace the I picture in the left store. The stores and predictors switch
designation because the left store is now a future P picture and the right store is now a past P picture. B pictures
between them are encoded as before.
5.14 Slices
In MPEG-1 and MPEG-2 I pictures and in MPEG-4 I-VOPs , the DC coefficient describes the average brightness of
an entire DCT block. In real video the DC component of adjacent blocks will be similar much of the time. A saving
in bit rate can be obtained by differentially coding the DC coefficient.
In P and B pictures this is not done because these are prediction errors, not actual images, and the statistics are
different. However, P and B pictures send vectors and instead the redundancy in these is explored. In a large
moving object, many macroblocks will be moving at the same velocity and their vectors will be the same. Thus
differential vector coding will be advantageous.
As has been seen above, differential coding cannot be used indiscriminately as it is prone to error propagation.
Periodically absolute DC coefficients and vectors must be sent and the slice is the logical structure which supports
this mechanism. In I coding, the first DC coefficient in a slice is sent in absolute form, whereas the subsequent
coefficients are sent differentially. In P or B coding, the first vector in a slice is sent in absolute form, but the
subsequent vectors are differential.
Slices are horizontal picture strips which are one macroblock (16 pixels) high and which proceed from left to right
across the screen and may run on to the next horizontal row. The encoder is free to decide how big slices should
be and where they begin and end.
In the case of a central dark building silhouetted against the bright sky, there would be two large changes in the DC
coefficients, one at each edge of the building. It may be advantageous to the encoder to break the width of the
picture into three slices, one each for the left and right areas of sky and one for the building. In the case of a large
moving object, different slices may be used for the object and the background.
Each slice contains its own synchronizing pattern, so following a transmission error, correct decoding can resume
at the next slice. Slice size can also be matched to the characteristics of the transmission channel. For example, in
an error-free transmission system the use of a large number of slices in a packet simply wastes data capacity on
 
Search WWH ::




Custom Search