2. 2
What is 'multimedia'
"multimedia" (literally):
– using more than one type of media usually
text, graphics, animation and sound to
produce an object.
• Traditional "static" Web pages,could be considered
multimedia, since they incorporate both text and graphics.
it is most often used to refer to the inclusion of
audio, video and/or animation in a Web
page.
3. 3
Categories of multimedia
application:
Streaming stored audio and video
Streaming live audio/video
Real time Interactive audio/video
streaming
allows users to play audio and video files before
they are completely downloaded.
4. 4
1.Streaming stored audio/video
Files are compressed and stored on either a:
– Web server
• HTTP protocol
OR
– streaming server
• non-HTTP protocols
Examples:
– For audio,
professor's lectures, rock songs, symphonies
– For video,
video of professors' lectures, full length movies, television shows,
video recordings of sporting events, cartoons and music video clips.
user interactivity
pause/resume and temporal jumps to the future and past of the audio file.
Delays
on the order of 1 to 10 seconds
5. 5
Streaming stored Audio/Video:
1.Using web servers
2.Using a web server with meta file
3.Using a media server
4.Using a media server and RTSP
6. 6
1. using web server
A compressed audio/video can be downloaded as a text file .
browser : send a GET message to download a file.
web server: sends the compressed file to the browser.
browser uses a help application (media player) to play the file.
One drawback : the file needs to download completely before it can be played.
7. 7
2.using a web server with metafile
1. The user clicks on a hyperlink for an audio/video file : request
Inf. about the meta file comes in response : response
The meta file contains the the URL of the actual audio/video file.
2. meta file is passed to the media player.
4. The media player sets up a TCP connection directly with the HTTP server.
The media player sends an HTTP request message for the audio/video file into the TCP connection.
5.the audio/video file is sent within an HTTP response message to the media player.
8. 8
3. using a media server
1.request: The HTTP client accesses the web server using a GET
message .
response:The inf about the metafile comes in response.
2.The meta file is passed to the media player.
3.The media player uses the URL in the metafile to access the media
server to download the file.
downloading can take place by any protocol that uses UDP.
The media server responds.
9. 9
4.using a media server and RTSP
1.The HTTP client accesses the web server using a GET message.
2.The inf. about the meta file comes in response.
3.The meta file is passed to the media player.
4.The media player sends a SETUP message to create a connection with the media
server.
5.The media server responds.
6.The media player sends a PLAY message to start playing (downloading).
7.The audio/video file id downloaded using another protocol that runs over UDP.
8. The connection is broken using the TEARDOWN message.
The media can send other types of messages ,e.x :PAUSE message temporarily stops
the downloading.downloading can be resumed with a PLAY message.
10. 10
2.Streaming live audio/video
similar to ordinary broadcast of radio and television,
the transmission takes place over the Internet.
Examples:
– Internet radio
– Internet TV
non-interactive
a client cannot control a server's transmission schedule.
Delays
up to 10 s from when the user clicks on a link until
audio/video playback
11. 11
3.Real-time interactive audio/video:
allows people to use audio/video to communicate with
each other in real-time.
Examples:
– Internet telephony
– Internet teleconferencing
interactive:
participants can orally and visually respond to each
other in real time
delay :
less than a few hundred milliseconds.
12. 12
Internet telephony =Voice over IP
By 2002:
– volume of data traffic :an order of magnitude
• (growing exponentially)
– volume of voice traffic : almost flat
• (5% growth per year)
Idea: use internet as telephone network
Instead of communicating over a circuit _switched
network,
they allow communication over packet_switched internet.
2 protocols to handles this type of communication: H.323 , SIP
13. 13
H.323
is a standard designed by ITU to allow
telephones on the public telephone network to
talk to computers connected to internet.
Gateway:
– connects internet to telephone network.
– It transforms the telephone network message to in internet
message.
14. 14
SIP:The Session Initiation Protocol
H.323 :complex, and inflexible
SIP defines telephone numbers as URLs,
– Web pages can contain them, allowing a click on a link to initiate a
telephone call (the same way the mailto scheme allows a click on a link
to bring up a program to send an e-mail message).
SIP can establish
– two-party sessions (ordinary telephone calls),
– multiparty sessions (where everyone can hear and
speak)
– multicast sessions (one sender, many receivers).
The sessions may contain audio, video, or
data, (multiplayer real-time games).
16. 16
Audio Compression
Audio compression can be used for speech or music.
Audio compression techniques
– Predictive encoding : differences between samples are encoded
instead of all sampled values; used for speech
– Perceptual encoding: uses frequency and temporal masking to
compress audio signals; used for MP3
The idea is based on some flaws in our auditory system:
some sounds can mask other
frequency masking, a loud sound in a frequency range can partially
0r totally mask a softer sound in another frequency range.
temporal masking, a loud sound can numb our ears for a short time
even after the sound has stopped
17. 17
Video compression
Video :
– is composed of multiple frames.
– each frame is one image.
compressing videos:
– first compressing images.
standards:
– JPEG : is used to compress images
– MPEG : is used to compress video
19. 19
JPEG
If the picture is not in color: each pixel can be represented by an
8_bit integer.
If the picture is in color:24 bits(3*8)
In jpeg a grey scale picture is divided into blocks of 8*8 pixels
Whole idea:
to change the picture into a linear(vector)
set of numbers
20. 20
each block of 64 pixels goes through a transformation that changes
the 64 values (through a formula)
The result of transformation:
Case1: a block of uniform gray :
the value of each pixel is 20
– dc value
T(0,0):non zero=average of the other values multiplied by a constant
– ac values
T(m,n): zero=represents the change in the pixels=here ,no changes
20 20 20 20
20 20 20 20
20 20 20 20
20 20 20 20
…
160 0 0 …0
0 0 0 ...0
0 0 0 …0
DCT: Discrete Cosine Transformation
22. 22
QUANTIZATION
Divide the number by a constant
Then drop the fraction.
– divisor depends on the position of the value
in the table.
We lose some information here that is not
recoverable.
JPEG is called lossy compression.
23. 23
compression
Removing redundant 0’s
to cluster 0’s together:
– we read the table diagonally in a zigzag fashion.
if the picture does not have fine changes ,the bottom
right corner of the table is all zero.
25. 25
MPEG
video = a sequence images,
with each image being displayed at a constant rate, e.x at 24 or 30
images per second.
2 types of redundancy in video, both of which can be exploited for
compression.
– Spatial redundancy
• the redundancy within a given image.
– E.x, an image that consists of mostly white space
– Temporal redundancy
• reflects repetition from image to subsequent image
– E.x If an image and the subsequent image are exactly the
same
Compressing video=
spatially compressing each frame and
temporally compressing a set of frames.
26. 26
How do I incorporate audio/video
files into my Web pages?
provide a text and/or graphic link to the file
– <A HREF=“myMusic.avi">
<EMBED> tag
– <EMBED SRC="MyMovie.mov", WIDTH=150, HEIGHT=250 >
– only for people who have a plug-in or helper app installed
client pull
– automatically downloads the file each time the page is
accessed
– <META HTTP-EQUIV="Refresh" CONTENT="1;
URL=myvideo.mov">
<BGSOUND SRC=“myMusic.wav">
27. References
Behrouz A. Forouzan :
Data communications , chapter28
James F. Kurose and Keith W. Ross:
Computer Networking , chapter6
Andrew S. Tanenbaum:
Computer networks , chapter7
27