That’s right. You heard me. Lossless video compression is pretty cool. It actually has a coolness factor of about 4.3 out of 5. That’s a lot when you think about it. In fact, TV’s “The Fonz” only has a coolness factor of 4.1, if that puts it into perspective for you.
But why is lossless video compression something we should care about, regardless of how cool it is? As part of my position as Digital Preservation Archivist at the Marriott Library, I’m tasked with creating a sustainable digital preservation program for the library’s unique digital collections and as part of that process, I’m making sure we also conserve server space. Uncompressed audio/video files take up a great deal more space than uncompressed text and photo files and that’s where lossless compression comes in. Lossless video compression refers to the fact that
the output from the decompressor is bit-for-bit identical with the original input to the compressor. The decompressed video stream should be completely identical to the original. – Ian Gilmour, R. Justin Davila
So, unlike lossy compression, lossless compression enables the need to store only the moving parts in any given image, without losing image quality when the original file is uncompressed. If, for instance a scene consists of The Fonz hanging out by his parked motorcycle, chatting up one of the waitresses at Al’s Diner, the compression scheme would be concerned with the objects that are moving within the frame (i.e. The Fonz, the waitress, the birds in the sky). The motorcycle and the diner aren’t changing at all, so there’s no need to store multiple copies of those images. When this scheme is kept internal to the image frame, this is referred to as intra-frame compression which is able to save large amounts of data when compared to the uncompressed file, which would store every pixel in the original image.
Inter-frame compression includes data from across the entire shot or scene. Entire sequences of frames with similarities can be encoded, with only the differences in the frames being specified. This means that the information not changing throughout the entire scene (rather than one frame as in the case of intra-frame compression) of The Fonz and the waitress can be compressed and later decompressed with no loss in image quality. Inter-frame is interesting because under certain conditions (typically when using lower bit-rates) the differences throughout a scene (known as temporal or inter-frame encoding techniques) require less data for picture quality than encoding every frame does.
Inter-frame encoding typically maps groups of pixels within macroblocks which stay the same from one frame to the next [i.e. fixed backgrounds] or which move in the same direction [e.g. moving objects or panned backgrounds]. Rather than encoding these image regions, their relative positions are tracked using motion vectors, which require much less coding.
- Ian Gilmour, R. Justin Davila
For a much more detailed look at lossless video compression, take a look at the piece referred to above by Ian Gilmour of the Australian National Film and Sound Archive and R. Justin Davila of Media Matters, LLC., Lossless Video Compression for Archives: Motion JPEG2 and Other Options.
And stay tuned to this blog for more on various recommended lossless audio and video compression codecs.