About compression

Sorenson Spark is a motion video codec included in Flash that lets you add embedded video content to Flash. Spark is a high-quality video encoder and decoder that dramatically lowers the bandwidth required to deliver video into Flash while simultaneously increasing the video quality. With the inclusion of Spark, Flash takes an important leap forward in video capability. In Flash 5 or earlier, you could only simulate video using sequential bitmap images.

Two versions of Sorenson Spark are available: Sorenson Spark Standard Edition is included in Flash MX 2004 and Flash Player 7. The Spark Standard edition codec produces good-quality video for low-motion content, such as a person speaking. The Spark video codec comprises an encoder and a decoder. The encoder (or compressor) is the component in Spark that compresses your content. The decoder (or decompressor) is the component that decompresses the compressed content so that it can be viewed. The decoder is included in Flash Player.

There are two different types of compression that can be applied to digital media: spatial and temporal.

Temporal compression identifies the differences between frames and stores only those differences, so that frames are described based on their difference from the preceding frame. Unchanged areas are simply repeated from the previous frame(s). A temporally compressed frame is often referred to as an interframe.

Spatial compression, on the other hand, is applied to a single frame of data, independent of any surrounding frames. Spatial compression can be lossless (in which no data is discarded from the image) or lossy (in which data is selectively discarded). A spatially compressed frame is often referred to as an intraframe.

Sorenson Spark is an interframe codec. Sorenson Spark's efficient interframe compression, among other features, distinguishes it from other compression technologies, requiring a much lower data rate than most other codecs to produce good-quality video. Many other codecs use intraframe compression; for example, JPEG is an intraframe codec.

However, interframe codecs also use intraframes. The intraframes are used as the reference frames (keyframes) for the interframes. Sorenson Spark always begins with a keyframe. Each keyframe becomes the main reference frame for the following interframes. Whenever the next frame is significantly different from the previous frame, the codec compresses a new keyframe.