One of the most confusing things in digital media playback on a PC is the use of Container Formats. This is to be expected as the average person should not need to know what a container is or why container formats are used. But, in today’s world that is not true, so here is some very basic information about Container Formats.
To start off, think of a Container Format as a standard shipping box. You get a box in the mail and you think, “Cool! What’s inside.” The fact that you got a box means little to nothing in the minds of most normal people. You don’t really care about the box itself, you care about what’s in that box. The problem? You can’t see into the box. So, what do you do? You get a knife and cut it open, right? Then you get the goods inside!
Container Formats follow this same basic idea. A few common containers are AVI, ASF, WAV, MP4, Ogg, and Matroska. For the rest of this post I will use AVI, as this is the main problem out there for most people.
So, now you have your AVI (i.e. a Box). You want to play this file, but before you can do that you have to “open the box”. You might think this is talking about going to File | Open in your favorite media player, but no! Way off. You need to get your knife and open it. Please don’t take a knife to your PC, in this example the “knife” will be called DirectShow for short. The magic of DirectShow “cuts open” your AVI and allows you to get the goods out. In the case of an AVI you have Audio and Video in there most of the time.
From there, DirectShow takes over again when and if you have the correct decoders installed to decode the Audio and Video that was/is “Inside” your AVI (Or box) At this point your box is open and you are enjoying what is inside! This can turn out to be another problem, however. The audio and video inside a container can be encoded with any codec. Windows Media Player supports playback of AVI files, but if the video is encoded with a third party codec (i.e. DivX) you must first install the DivX Codec from DivXNetworks (Or a compatible decoder) for Windows Media Player to truely “play“ the file. Without the correct decoders Windows Media Player will just error out, and the video and/or audio might not be ouput.
This is a very simple explanation of what a container is, I could go in much more, but the average person does not need to know anymore then that.