Prologue
Multimedia compression has allowed us to communicate information and expression in novel ways as the unsung hero of the modern Web. Despite this, it is often difficult to uncover information about codec technology that is accurate, informed, and accessible. This wiki aims to demystify multimedia compression while connecting codec enthusiasts to create a sink of knowledge for everyone.
The Codec Wiki is not geared toward the mathematics, adoption/patent politics, or specifications of specific coder/decoder implementations â sources like Wikipedia cover these details. We are focused on making accurate, useful information highly accessible.
What is a Codecâ
A codec, shortened from coder/decoder, is a system that handles digital data according to a specification. Typically this means compressing and decompressing digital media. Codecs are used to encode media for storage and transmission, and then decode for playback, editing, etc. Multimedia codecs generally either discard data using lossy compression to reduce filesize, or they use clever lossless compression tricks to maintain a mathematically identical stream to the input media while still reducing filesize. Lossless compression can be reversed to be the exact same as the input data, while lossy compression does not share this quality as it discards data for smaller filesizes. Some common uses of codecs include:
- Video compression: Video codecs like H.264, VP9 & AV1 allow digital video files to be compressed to much smaller sizes. A video codec can encode a video stream while it is being recorded or before it is distributed, and decode it when it is played back. This allows video to be shared more quickly while using less storage & bandwidth.
- Audio compression: Audio codecs like MP3, AAC, and Opus compress audio files like songs & podcasts. This allows them to be easily distributed & stored.
- Image Compression: Image codecs compress images while maintaining a versatile featureset for the myriad of ways one may decide they'd like to compress an image. Color depth, HDR, transparency, color space information, EXIF data, and many other factors are relevant when working with images.
- Data Compression: General compression algorithms like ZIP & zstd are designed to compress any kind of data, not just multimedia specific data. This includes web assets, executables, text archives, and even entire filesystems.