Creating 3D Animation

 

Compressors and Decompressors

used for: Digital Video and Digital Photography

Because of the large amount of data contained in a digital image, and because digital video contains sequences of thousands of digital images, compression is used to reduce the size of the digital video files. Compression algorithms use many different techniques (and often several techniques at once) to reduce the size of files. All compressors attempt to identify redundent data (groups of pixels that are the same color or almost the same color.) Still image compressors have to work only with a single frame, and use intraframe compression (i.e. the data being compressed is within the frame.) Compressors that work with sequences of images can use intraframe compression, but also will use interframe compression. That is, they identify redudndent data between frames. Interframe compression, while it can greatly reduce the size of a sequence of frames, makes it difficult to randomly access parts of a movie. This is because you can't just display frame 4 of a movie if interframe compression has been used. To display frame 4 accurately you must first read in frames 1 through 3 because they will contain information that is used in frame 4.
For this reason, when using interframe compression, a keyframe is usually introduced every x frames (where x is usually equivalent to the fps [frames per second] used for the movie.) A keyframe stores the entire frame without using interframe compression.
As an example, if a sequence is captured at 15 frames per second, and every 15th frame is a key frame, then is you want to see frame 63, the display engine only has to read frames 60 through 63 to display the frame, rather than frames 1 through 63 if key frames weren't used. While the resulting movie is larger, the ability to randomly jump within the movie more than makes up for this.

There are a wide variety of compression algorithms available; though the most common are:

  • JPEG
    Usually used for still images, but sometimes used for sequences
  • MPEG
    There are a number of different MPEG variations, MPEG is optimized to the specifications of television formats, so some MPEG compressors only work with specific resolution sizes (such as 320 x 240)
  • Cinepac
    General purpose compressor that was originally developed for creating sequences that play from CD-ROM players.
  • Sorenson
    A "new" compressor which is optimized for web transmission.

 

codec
Abbreviation of compressor/decompressor. Usually used to refer to the compression decompression code that is used in video compression applications. QuickTime, for example, comes with several codecs included (such as Cinepac, Sorenson, JPEG) other codecs can be added by purchasing third-party plug-ins.
Codec Central is a good source for third party codecs for QuickTime.

 

Symmetrical vs. Asymmetrical compressors
Compressors are sometimes classified as being Symmetrical or Asymmetrical. This refers to the amount of time and processor power needed to compressor a sequence versus decompress it. A compressor that is symmetrical takes about the same amount of power to compress as it does to decompress. This is really only important, or of interest when talking about capturing and authoring digital video. In theory a symmetrical compressor can be used to capture the video in real time and then used to play it back. Apple's Video Compressor is virtually symmetrical; a sequence can be captured in real time and then played back. Unfortunately, the quality of the compressor is no where near as high as that produced by Cinepac, which is an asymmetrical compressor.

In reality, the most important difference is between software and hardware based compressors. Hardware based compressors, because of their significant performance advantage, can be used to compress a sequence to disk in real time that it would be impossible to do with a software compressor.

last updated: 5/27/98

| Multimedia Workshop | Industry News | Online Reference | Contact Us | Find |

Copyright 1998 by Multimedia Workshop. All rights reserved