Trig home page











 
   
Streaming media



Principles

What is streaming?

Normally files are downloaded from the internet in one go. You have to wait for the whole file to download before you can do anything with it. This is okay for small files but doesn't work for large files such as video or audio.

Streaming works by having special software on both the server and the client. Both bits co-operate so that as soon as the client thinks it has enough information to start showing you things, it does so without waiting for the rest of the information to arrive.

The client and the server maintain a constant two-way communication. Because of this you can fast-forward, pause, and reverse the data stream, jump to random points in the file, or charge people on the basis of how much of the file they see. This can't be done on normal file downloads.

More importantly, this two-way communication means you can make more effective use of network bandwidth. If you are using an xDSL internet connection, where the available bitrate can vary considerably, the player and server can talk to one another to ensure you always recieve the best possible connection for your current bit rate. If the server goes down or is overloaded, you can be automatically swapped to a new server. As the owner of the stream you can monitor viewers and use the constant communication as a basis for pay-per-view (PPV).

A downside is that this can sometimes cause firewall problems. Firewalls are often only configured to allow information to go one way, and the player requests being sent can sometimes look like an attempt to get unauthorised network information. This depends upon both the network settings and the transport protocol used by the media server.

Streaming media usually refers to audio and video files but text, pictures, advertisements and so on can also be streamed; effectively, anything that can go on a web page. Streaming media files can be downloaded, placed on a CD, emailed etc the same way as other files, and local copies can be played without a special server.

Encoding, serving and playing

As well as the client program and the server, there needs to be encoding software. This is required for audio and video files, but not for data already in a web-ready format such as GIF images or hypertext links.

The encoding software creates files in a particular format. The client and server program needs to be able to read this format, but typically the server program will handle many different formats. For example, files encoded for Windows Media Encoder can only be played in Windows Media Player, but both Windows Media Server and RealServer will stream the files. An MP3 file can be streamed by RealServer and then played in both players.

Data can be encoded from live sources such as running video cameras or microphones at a conference; or from closed sources such as a video tape or digital audio recording. Multimedia data files can also be converted to streaming media formats. For example MPEG movies can be converted to RealNetworks or Windows Media formats by the relevant encoders.

There are currently three dominant players in the market. RealNetworks, Microsoft, and Apple. All these companies produce encoders, servers and players. The players need to be installed on the client machines before the multimedia files can be seen. There are also a number of smaller companies producing Java-based solutions which do not need installed players but upload the relevant code as needed.

Different media files can be linked together; for example, subtitles with video, slides with an audio broadcast, adverts with HTML pages. Each media system has its own way of arranging for multiple things to happen simultaneously, usually by encoding the instructions and timings in the dominant media file.

There is also an open standard called SMIL (Synchronised Multimedia Integration Language) which uses program scripts to co-ordinate multiple events. As such it is rather like HTML or XML; in fact it is part of the same family of languages. SMIL is extremely powerful yet easy to use. However, at the time of writing only RealNetworks supports SMIL, and that only a subset.

Live, on-demand and simulated live broadcasting

Streaming media can be sent out in three ways. A live broadcast is where an event is being recorded, encoded, and sent out over the network in real time. Everyone logging in to the system will see or hear the broadcast at the same point:

live webcast diagram

You cannot fast-forward or reverse. If you 'pause' the broadcast, when you press 'play' again it will jump forward to the current position. This is akin to watching a live TV broadcast.

On-demand broadcasting is where the recording and encoding is separated from delivery. The encoded files are placed on the server. Clients logging in to the server will see the file from the beginning, but they will be able to move backwards and forwards through the presentation at their own pace. So, at any one time people viewing the broadcast will be seeing it at various different points:

on-demand webcast diagram

Thus, on-demand webcasting is like having a video available for rent.

Simulated live broadcasting combines the two. The event is pre-recorded and encoded, but it is sent out as a live event so that all viewers see the same thing at the same time:

simulated-live webcast diagram

This is the equivalent of a pre-recorded TV broadcast.

Practicalities

Before webcasting you need to address a number of basic issues.
  • live or prerecorded?
  • audio or video?
  • the capabilities of your recording system
  • the capabilities of your viewer's machines
  • network connections
  • do you need two-way interaction?
For some of these the answers will be determined by the limits of your resources. In other cases, your choices will affect the options available to the viewer.

You first need to decide the audience, which will largely determine the media format and encoding algorithm used. Generally for audio you can get away with old algorithms, so that people with players over a couple of years old can listen without upgrading. However, for video use algorithms (if you can) later than September 2000, when video quality for both RealNetworks and Microsoft systems took a significant step forward.

For recording and encoding you need the A/V source, a computer, some hardware to connect the two, and encoding software. For audio you can plug audio sources into a standard computer sound card. The necessary power of the computer depends upon the bitrate of the stream(s) you want to encode, but most PCs under a couple of years old should be powerful enough (ie a P266/P300 is okay).

For video recording you need a video capture card or some other connection such as FireWire. A webcam connects directly to the computer. Video encoding requires more processing power; at least a Celeron 500. Don't use the computer for anything else during a live capture - encoding programs are frail.

In both cases for live webcasts you should have a second computer on site for back up encoding and to observe the web output. You also need to have sufficient bandwidth to the server to cover your broadcast. Audio broadcasts from a modem can give quite acceptable quality, but for video dual ISDN (128kbps) is a reasonable minimum specification.

If you're pre-recording things encoding bandwidth is not an issue. You put a file on a disk and send it to your ISP.

You will require a specialist server. Except for broadcasts to small numbers, this costs money; live broadcasting is particularly expensive. Costs usually depend upon broadcast length and bandwidth; on-demand costs also depend on the size of stored files. Some companies will charge you on exact usage; others will have flat charging bands.

Many companies offer streaming services, including most major ISPs; however, prices and service levels can vary greatly.


The main streaming media programs

Programs and formats

There are three dominant companies in this market. RealNetworks is the major player with up to 80% of the streaming media market in RealMedia formats or using RealMedia servers. Microsoft is second, with the Windows Media system. It has a far larger share of the non-streaming market. Apple comes third, with QuickTime being used for streaming movies. Finally, there are also a number of Java-based applets on the market.

Each system has an encoder, a server and a player. These systems work with a variety of digital formats, but no system supports all file types.

RealNetworks

RealNetworks systems, which go under the collective name of RealSystemTM, are the most flexible of the three major players. RealSystem is a powerful set of programs designed purely for multimedia streaming. This shows in the way that setting up the server, encoding and playing streams, and creating web pages is all very simple.

One of the most powerful features of RealSystem is that it can incorporate multiple bandwidth streams in one composite stream. The effect of this is that only one "play" button is needed on a website to start a presentation, irrespective of the viewer's current internet connection. The stream will also respond to degraded network conditions by adjusting the stream automatically.

RealSystem servers are easy to set up and administer and offer a number of powerful features, including multicasting, pay-per-view, authentification, chaining and failover. They will serve all the main media file types including Windows Media and QuickTime, although you still need the correct viewer at the end user.

RealSystem can use the standard HTTP protocol; however, by default the RTSP protocol is used. This is much more efficient than HTTP but it can cause firewall problems. Although the RTSP protocol is well known, the ports used are often not set up by default in corporate networks as they do present a potential security problem.

RealSystem understands SMIL, at least in a slightly customised version. This makes it relatively easy to compose complex multimedia presentations. Because SMIL is controlled by text files, these presentations can be created on the fly and targeted at particular users.

RealSystem is the only system that supports a full range of operating systems at all stages. The encoder, server and player are available for Windows, Macs and popular flavours of Unix and Linux.

RealPlayer Basic comes as a standard plug-in with Netscape, or it can be downloaded from the RealNetworks site.

Windows Media

The Windows Media system is designed for local applications. Hence, although it includes streaming media capabilities, its strongest features are its integration with local applications.

Windows Media is designed to integrate completely with the Windows environment. It provides native links to the Windows APIs, makes extensive use of ActiveX, and can be easily accessed through Visual BasicTM. Windows Media thus has a readily defined set of tools to integrate with other programs, in contrast to RealSystem where the API is both limited and relatively obscure. Windows Media can do anything.

The downside of this is that it is difficult to do simple things in Windows Media - like creating a basic linked sound/slides archive. Setting up streaming is far more complicated than in RealSystem because the options are so much larger. Similarly, because it is designed to do everything it does not stream media as easily or as effectively as RealSystem. Creating multimedia presentations requires the Resource Kit, a collection of almost twenty programs to do various specialised tasks.

One other major disadvantage of Windows Media is that it is encoded for a specific bandwidth. Thus to provide multiple bandwidth options your web site needs to have multiple buttons.

However, the Windows Media Encoder has one extremely useful feature: it will stream directly from the encoder without the need for a server. If you have adequate bandwidth and a limited number of viewers, this is a large potential cost saving - particularly for home users.

Windows Media uses the HTTP protocol which, although less efficient than RTSP, causes fewer problems with firewalls as this is the default protocol for web pages.

The current version of Windows Media Player runs on Windows 2000, Windows XP, Windows ME/98, Macs and Solaris. It is not available for Windows NT or Windows 95. The encoder runs on Windows 98/ME, 2000 and XP. The server requires Windows 2000 or XP.

Windows Media Player comes automatically with Windows 2000, Windows XP and Internet Explorer 6. The Windows Media Player that shipped with Windows 98 (mplayer.exe) is a very old version of limited use. The server ships with server versions of Windows 2000 and XP. The complete suite of programs can be downloaded from the Windows Media website.

Apple QuickTime

Apple QuickTime is a popular format for movies, and is common on promotional CDs. It is available for both Windows and Macs, and will play MP3 and AVI files. However, it will not play RealSystem or Windows Media files, and only plays MPEG files in its latest version.

QuickTime has a small portion of the streaming market, but its presence is far outweighed by the other systems. Its main market is in local movie files.

QuickTime uses RTSP as the streaming protocol. It has limited support for streaming composite presentations, but many more tools fro creating interesting movie effects for local playing. As such, it is more akin to Windows Media than RealSystem.

QuickTime plays on all versions of Windows and Macs. There are two versions of the server: one for Mac OS and one (called Darwin) for Windows, Linux, Solaris and FreeBSD. The Darwin version is on open-source project.

The player only ships automatically with Macs, but is often found in promotional CDs. The server ships automatically with the Mac OS server versions. Programs can also be downloaded from the QuickTime site.

Java solutions

There are also a variety of Java-based solutions where the client downloads a Java applet to handle the streaming. This does not require the client to have a specific program pre-installed on his machine. It does assume that the client has permission to run Java applets (not necessarily true for corporate networks). There is also an additional delay while the applet is downloaded. Picture quality is variable.

Further information

For further information, please contact webcasting@trigconsulting.co.uk.

Windows MediaTM is a trademark of Microsoft Corporation. RealPlayerTM and RealSystemTM are trademarks of Real Networks, Inc. QuickTimeTM and DarwinTM are trademarks of Apple Computer Inc.
   


[about]   [services]   [partners]   [contact]
Copyright © 2001 Trig Consulting Ltd