An overview of how to stream video and music for Apple enthusiasts.
QuickTime is Apple’s platform-independent suite of files,
applications and plug-ins for playing or interacting with a wide range of
popular media formats — everything from movies to live streaming video to
Flash animation to MP3 music files to interactive 3D environments.
QuickTime Streaming Server
QuickTime Streaming Server lets you start up a streaming
digital video channel with news, entertainment and education programming–on
the Internet. Apple makes the QuickTime Streaming Server source code available
to whoever wants to improve it so that it continues to evolve.
-
Serves QuickTime
files stored on the server (video on demand) -
Supports more
than 2000 streams to QuickTime users concurrently -
Supports hundreds
of stored files -
Acts as a
reflector for live broadcasts -
Provides access
control to media files using authentication modules -
Compliant with
Lariat
QuickTime Streaming Server is included in Mac OSX Server.
Being optimised for Power Mac G4, it serves live streams of audio and/or video
with industry-standard Internet protocols RTP/RTSP or QuickTime files formatted
for HTTP via the Apache Server (also included).
QuickTime Streaming Server provides the choice of two
different streaming methods–HTTP streaming and RTP/RTSP streaming:
HTTP works by downloading an entire movie to your viewer’s
hard disk.
RTSP (Real-Time Streaming Protocol) keeps the viewer’s
computer in constant touch with the server running the movie. Digital data is
transferred and displayed–then discarded once the viewers
have watched it.
The difference–HTTP streaming is great for short movies and
repeat playback. RTSP streaming, on the other hand, is ideal for full-length
movies and live events.
QuickTime Tracks
Each element of a QuickTime movie is contained in a separate
track. A QuickTime movie is made by adding tracks that point to the media under
use. The media may be embedded in the movie itself, or reside on a server half a
world away. This track architecture is powerful and flexible and provides the
control and precision one needs, to create complex interactive movies.
Each track represents a unique aspect or ability that one can
change over time. A single movie may have many different track types, including
video, audio, text, sprit, Flash, HREF, hinting QuickTime VR and chapter
divisions. Each track, in turn, may possess many modifiable properties.
Creating Video and Audio Tracks
Video and audio tracks are the most common forms of QuickTime
media tracks. A QuickTime video track can be created from digital video (DV),
digitised analog video, a 2D or 3D animation program, or any other source
capable of generating an image sequence in any of the file formats importable
into QuickTime. Movies can have many video tracks, which can be edited, layered
and have effects and transitions applied to them. One has complete control over
such properties as frame size, frame rate (frames per second), data rate and
video compression.
-
Video
compression: Video compression is necessary to make the movies play at full
speed on most computers or to be small enough to view on the web. QuickTime
supports a wide rage of codecs (compressors-decompressors), both lossless
(high quality, large files) and lossy (lower quality, small files). To see
the codec options, export the movie (using Export... in the File menu) as a
QuickTime movie, choose Options... and then Video Setting ...The Apple
Sorenson codec is recommended as a high-quality lossy codec for video and
rendered animation. -
Audio
compression: QuickTime offers a variety of sound and music compressors.
QDesign’s music codec is recommended for its high quality and small-size
files.
Streaming Using QuickTime
Streaming is the process of sending media over a network for
viewing in real time. The data is simply being displayed as it arrives by the
QuickTime plug-in and in QuickTime Player no copy remains on the viewer’s hard
disk.
Viewing a Stream
One can view streamed media by:
-
Tuning in
directly to a live or pre-recorded broadcast using QuickTime Player -
Using QuickTime
Player to view multimedia on demand -
Using a web
browser to point to a web page that has streamed media embedded in the page
Fast Start Movies
With QuickTime, one can watch movies as they download using
ordinary HTTP or FTP transfer protocols. This is not streaming but a unique
feature of QuickTime called Fast Start or Progressive Download.
With Fast Start, the audience can download an entire
QuickTime movie at the highest data rate that their connections can support. As
soon as the initial part of the movie has been downloaded, QuickTime Plug-in
begins to play it back in the browser while it continues to download the rest.
The audience is left with a complete movie file that they can save and replay as
often as they want. No special streaming software on the server is needed. All
that one needs to create is a Fast Start movie (which you can do using QuickTime
Player) and embed it in the web page.
A Fast Start movie can start playing long before the whole
file has downloaded–typically within a few seconds of starting the file
transfer. If the net connection is faster than the movie’s data rate, the
movie plays smoothly as it arrives, with no waiting. It’s an optimal
experience for the audience. A Fast Start movie can also include pointers to
data located in other files on the web server, a local disk or CD, or any web
URL.
Transport Protocols
QuickTime streams are sent using Real-Time Transport Protocol
(RTP). RTP is similar to the more familiar HTTP and FTP file transfer protocols
but it is tailored for the special needs of real-time streaming.
Unlike HTTP and FTP, RTP does not download an entire movie to
the client computer. Instead, it siphons out a thin, one-way data stream at a
constant data rate that plays the broadcast in real time. A streamed one-minute
movie plays in exactly one minute. As long as the connection has enough
bandwidth to handle the data stream, the movie will play. After the data is
displayed, it is discarded. Viewers can see the broadcast again only by
requesting it from the streaming server.
RTP vs. RTSP
It is important to distinguish between RTP and Real-Time
Streaming Protocols. RTSP is used when viewers communicate with a unicast
server. RTSP allows two-way communication, that is, viewers can communicate with
the streaming server and do things like rewind the movie, go to a chapter and so
on. QuickTime automatically translates the viewer interaction with the
one-screen movie controller into the proper RTSP requests. By contrast, RTP is a
one-way protocol used to send live or stored streams from the server to the
client.
How Live Streams are Handled
When you tune into a live broadcast, the QuickTime streaming
client (for example, QuickTime Player or the QuickTime Plug-in) sends a request
to the QuickTime Streaming Server. The server looks for a Session Description
Protocol (SDP) file and if it is found, it begins to stream the media onto the
computer via RTP. An SDP file is a text file that contains information about
what will be streamed and how to tune in. SDP files are created by broadcast
software (such as Sorenson Broadcaster) on the computer that captures the live
media but the SDP file must be copied to the streaming server before the media
can be broadcast. QuickTime Player and the QuickTime Plug-in can open SDP files
as if they were movies.
Transport Issues
Real-time streaming involves some data transport issues:
-
Data loss:
RTP uses low-level User Datagram Protocol (UDP) transport. UDP is faster and
more efficient than TCP/IP, but it lacks a mechanism for reporting lost
packets, so streaming over the Internet almost always involves some data
loss. -
Firewalls:
Because most firewalls block UDP, viewers behind a firewall may not be able
to receive live streams, even though they can request them via RTSP. A proxy
server software is needed to get around this. Apple provides proxy servers
for most popular firewalls. -
Network
address translation: Small networks using routers to connect to the
Internet may also have problems receiving streaming movies. These routers
typically use Network Address Translation (NAT) but streaming over RTP
involves port addresses that confuse some older NAT software. -
HTTP
tunnelling: When everything fails, use HTTP tunnelling to
"wrap" the RTP packets inside ordinary HTTP packets. This usually
allows the stream to pass through any firewall or NAT router. To enable HTTP
tunnelling, each viewer must configure their QuickTime Settings control
panel by checking ‘Use HTTP’ and setting the port to 80 (or the port
used for HTTP transfer by your streaming server) and the server must be set
up to support HTTP tunnelling.
FastStart vs. Streaming.
When deciding on the best way to deliver QuickTime movies
over the web, what should be chosen–Fast Start (HTTP/FTP delivery) or
streaming (RTP/RTSP delivery)? For live feeds that must be transmitted in real
time, streaming is the only answer, but for other types of movies, each delivery
method has its own pros and cons.
MM Vijay Sargunar and M Syed Masood, Department of Computer
Science, Engineering and Applications, Crescent Engineering College, Chennai
Types of Quick Time Track
Types of Quick Time |
|
Movie Track |
Contains copyright information, annotation and other general information on the entire movie. |
Video Track |
Digitised video, rendered 3D animation, or any other complied image sequence, with optional special effects. |
Audio Track |
CD-quality audio or other audio formats. |
Music Track |
MIDI music with QuickTime |
Text Track |
Text imported into QuickTime for titles, sub-titles, credits, notes and other uses. |
Chapter Track |
A type of text track that divides the movie into randomly-addressable chapters |
Sprite Track |
Contains one or more small images with animatable, programmable behaviours useful for signs, symbols, games and effects. |
3D Track |
Contains 3DMF (QuickDraw 3D metafile) objects. |
Flash Track |
Incorporates SwF Flash animation |
QuickTime VR or VR Object Track |
QuickTime VR information for object movies. |
QuickTime VR Panorama Track |
QuickTime VR information for panorama movies. More on QuickTime VR. |
HRFF Track |
Text track containing interactive or automatic URL links. |
Streaming Track |
Contains a reference to a live stream or a movie on a streaming server. |
Hint Track |
Contains information that allows a streaming server to deliver a media track as a real-time stream. |
Â
Streaming Using QuickTime
A sample set-up for broadcasting live video.
The illustration below shows a set-up for streaming live video and audio.
Stream audio only using a microphone, mixer and other appropriate audio
equipment.
The broadcaster computer captures and encodes the video and audio. The
encoded signal is sent to a QuickTime Streaming Server over an IP network. A Mac
OSX Server, with QuickTime Streaming Server, sends the signal to client
computers who tune in with QuickTime client software, such as QuickTime Player.
The broadcaster computer digitises and compresses the video and audio feed.
The data stream is routed through Sorenson Broadcast, which configures it for
broadcast, and sent out to a high-speed IP LAN. The data is received by a
streaming server running Mac O/S X Server and QuickTime Streaming Server (or
either open-source equivalents). In this example, the streaming server acts as a
multicast reflector. The streaming server feeds the stream to an MBone
(multicast backbone) and/or to a unicast reflector connected to the rest of the
Internet.
What’s needed?
To deliver live QuickTime streaming media, the following are
required:
-
Audio-visual
equipment to record the live event. -
An A/V-equipped
computer (the broadcaster) to digitise and compress the live data and then
broadcast it to the streaming server. -
Broadcasting
software such as Sorenson Broadcaster, a transmitter application that
compresses video and audio and configures it for live streaming. -
A high-speed PI
network. -
A dedicated
streaming server (the reflector) capable of running Mac OS X Server with
QuickTime Streaming Server installed. Use this server to send the captured
media to the viewers. The streaming server must be connected to the
broadcaster computer over an IP network. -
A connection to a
multicast backbone (MBone). -
Optional - a
third computer to act as a unicast reflector to stream out to areas where
the web is not accessible through an Mbone.
Steps to be taken to set-up streaming live video or audio:
-
Set up the
broadcasting software following the instructions that came with it. -
Connect the audio
or video equipment to the computer you are using to capture and encode the
signal. -
Use the broadcast
software to create a Session Description Protocol (SDP) file on the computer
under use to capture and encode the live signal. See the instructions that
come with the broadcast software. -
Copy the SDP file
to the QuickTime streaming server computer. Be sure to copy the file into
the media folder that is being used for streaming. If it is not there,
steaming will not happen. -
Set up the web
page to show the streamed media. -
Copy the SDO file to the
QuickTime Streaming Server computer. Be sure to copy the file into the media
folder that is being used for streaming. If it is not there, streaming will
not happen.