Understanding Codecs and Formats

Understanding Codecs and Formats

This post is a part of our educational series on Live Streaming Basics for the Newbie and Video on Demand Basics for the Newbie.

Audio and Video Codecs

A Codec is technology used to compress the data. Common video codecs (also called video format) include MPEG-4/H.264 and WebM(VP8). Common Audio codecs are AAC and MP3. Different players accept different types of codecs. For example, YouTube live player accepts only H.264 video codec. The figure below depicts the creation of an encoded video file from original video and sound files.

Creation of an encoded video

Container Format vs. Video Format

A Container or wrapper format can literally be thought of as a container for the actual video. It defines how the video, audio and other data is stored within the container.  If you want to change the way the data is being read, you can swap out the container without changing the file type. The process of changing the container format of a file for delivery to a different target platform is called transmuxing. One of the biggest sources of confusion about video is not realising that the file format (aka container format) is completely different from the video format (the video codec). Examples of file formats i.e. container formats are .mp4, .flv, .ogv, .mov and .avi. Flash (.flv) is a container format that utilizes H.264 for Video and AAC for Audio. The flash container could also hold video encoded with vp6 instead of H.264. More examples of containers are shown in the picture below.

Container formats

You now know how Codecs work and how container formats differ from video formats. To learn more about containers and the role they play in streaming, check out our post on adaptive streaming.

Fundamental Concepts

If you want to learn more, a few more fundamental concepts are covered in the following posts in this series:

Encoding Courses

If you feel you need to dive into further detail, Udemy has a great online course on Encoding for Multiple Screen Delivery by Jan Ozer from Streaming Learning Center.

Leave A Comment

Your email address will not be published. Required fields are marked *