Typically, pictures (frames) are segmented into macroblocks, and individual prediction types can be selected on a macroblock basis rather than being the same for the entire picture, as follows:
- I-frames can contain only intra macroblocks
- P-frames can contain either intra macroblocks or predicted macroblocks
- B-frames can contain intra, predicted, or bi-predicted macroblocks
Furthermore, in the video codec H.264, the frame can be segmented into sequences of macroblocks called slices, and instead of using I, B and P-frame type selections, the encoder can choose the prediction style distinctly on each individual slice. Also in H.264 are found several additional types of frames/slices:
- SI‑frames/slices (Switching I); Facilitates switching between coded streams; contains SI-macroblocks (a special type of intra coded macroblock).
- SP‑frames/slices (Switching P); Facilitates switching between coded streams; contains P and/or I-macroblocks
- multi‑frame motion estimation (up to 16 reference frames, or 32 reference fields)
Multi‑frame motion estimation will allow increases in the quality of the video while allowing the same compression ratio. SI- SP‑frames (defined for Extended Profile) will allow for increases in the error resistance. When such frames are used along with a smart decoder, it is possible to recover the broadcast streams of damaged DVDs.
Read more about this topic: Video Compression Picture Types