How Streaming Video and Audio Work

  Prev Next  

Streaming Files

OK Go's video for the song "Here it Goes Again" plays in a small window on YouTube.
OK Go's video for the song "Here it Goes Again" plays in a small window on YouTube.

Streaming video and audio files are compact and efficient, but the best ones start out as very large, high-quality files often known as raw files. These are high-quality digital files or analog recordings that have been digitized, and they haven't been compressed or distorted in any way. Although you can watch a streaming file on an ordinary tv, editing the raw file requires lots of storage space and processing power.

It might seem strange that a file that ends up nimble and efficient started out large and unwieldy. The reason is that the compression process, required to make an ordinary file into a streaming file, lowers the file's quality. During compression, blurry, low-quality videos or hard-to-hear audio recordings will only get worse.

Fortunately, before you even compress a file, you can reduce its size without lowering its quality:

  • Make the picture smaller: Most streaming videos don't fill the whole screen on a computer. Instead, they play in a smaller frame or window. If you stretch many streaming videos to fill your screen, you'll see a drop in quality.
  • Reduce the frame rate: A video is really a series of still images. The frame rate is how quickly these images move from one to the next. A lower frame rate means fewer total images and less data needed to recreate them. The reduction in frame rate is why some streaming videos flicker -- the frame rate is slow enough that your eye and brain sense the transitions between pictures.
In YouTube's full-screen mode, the picture is fuzzier and more pixilated.
In YouTube's full-screen mode, the picture is fuzzier and more pixilated.

For both video and audio files, making the files even smaller requires codec, or compression/decompression software. Codecs discard unnecessary data, lower the overall resolution and take other steps to make the file smaller. Different codecs also create specific types of files, which work on specific streaming players.

The total reduction in quality depends on a number of factors, including the bitrate, or the speed of the transfer from the server to a computer. For example, the bitrate of a television broadcast is about 240,000 kilobits per second (Kbps), but the bitrate of a dial-up Internet connection is a maximum of 56 Kbps. Someone with a reliable broadband connection with lots of bandwidth can watch high-bitrate files, but someone using a dial-up modem needs to watch at a much lower bitrate. The basic idea is to encode a file that's large enough to look or sound good but small enough to work with the available bandwidth. Some codecs let you create files that will stream differently at different transfer rates, accommodating different connection types. This is known as multi-bitrate encoding.

Once a file is edited, compressed and encoded, it's uploaded to a server. We'll look at the server's role in streaming media in the next section.