lecture 17 – march 21, 2002
DESCRIPTION
Lecture 17 – March 21, 2002. Content-delivery services. Multimedia services Reminder next week individual meetings and project status report are due. Content-delivery services. Multimedia Services. Voice over IP Still images Audio broadcast Video broadcast Video on demand - PowerPoint PPT PresentationTRANSCRIPT
1
Lecture 17 – March 21, 2002
Content-delivery services.
Multimedia services
Reminder next week individual meetings and project status report are due.
2
EdgeRouter
EdgeRouter
EdgeRouter
EdgeRouter
EdgeRouter
EdgeRouter
Local ISP Local ISP
Local ISP
Local ISPLocal ISP
Local ISP
ContentProvider
ContentDelivery
ContentDelivery
ContentDelivery
ContentDelivery
ContentDelivery
Content-delivery services
3
Multimedia Services
Voice over IP
Still images
Audio broadcast
Video broadcast
Video on demand
Teleconferencing
Videoconferencing
Remote instrumentation
Telemedicine
4
Analog and Digital Information
Sampling – Nyquist theoremQuantization – quantization noiseExamples:
voice – sampling rate 8,000 samples/sec 8 bits/sample-256 quantization levels music – sampling rate 48,000 samples/sec 16 bits/sample color video – 10,000,000 samples/sec 24 bits/sample
5
Timing requirements for data streaming
Interactive service – voice over IP, teleconferencing delay and jitter sensitive but loss tolerant
Video streaming rate sensitive and to some extent loss tolerant. 25 frames/sec
Telemedicine and remote instrument control delay and loss sensitive
Stored media applications – video on demand less strict/demanding
6
Delay and JitterPlay-out delay
End-to-end delay Delay at the sender Data transmission and propagation delay Delay at the receiver
Jitter – variability of end to end delay
For a normal conversation – play out delay < 100 msec not noticeable < 400 msec acceptable > 400 msec not acceptable
7
Delay and Jitter
agt
ast b
gtapt
art
generationtime
receptiontime
playbacktime
bst
sending time
packets
b
a
brt
bpt
time
8
Removing the Jitter in Voice over IP
Fixed play-out delay
Adaptive play-out delay takes advantage of silent periods between talk spurts
Fill in a buffer at a variable rate and drain it at a constant rate.
9
Data Streaming
Data stream – sequence of bytes flowing out or into a process.
Media server
Media player
Often they require a Web browser to connect to the server and download a metafile describing the media player.
10
WebBrowser
MediaPlayer
Http server
Multimedia database
HTTP request
HTTP response - metadata
Commands - TCP connection
Data stream - UDP
Client
ServerThread
ServerCache
11
Error Recovery Schemes
Forward error correction – sender adds redundant information.Packet (i) contains the original information and
a low-quality version of packet (i-1)
Interleaving the stream is scrambled. Packet (i) does not contain samples adjacent
to each other.
12
Real-time Protocol (RTP)
RTP – application layer protocol
Uses UDP; TCP congestion control and error control prevent delay or rate guarantees.
RTP supports several audio formats including PCM, GSM, G.722,
MPEG audio – MP3video formats – JPEG, MPEG 1, and MPEG 2.
13
RTP
One may have multiple RTP connections; one for audio and one for video
RTP supports unicast and multicast
RTP packet: Header + PayloadHeader
Payload typeMagic number to identify the audio or video formatSequence number of the packetTime stampRandom number associated with the RTP session
14
RTCP – RTP control protocol
Senders – periodic source reportsRTP session identifierApplication generating the streamAddress of source
Receivers periodic reciver reportsNumber of packets lostJitterNumber of packets Received
15
RTCP
An application may use may use the data provided by RTCP toModify transmission ratesSynchronize multiple streamsDiagnostics
For multicast RTCP limits the frequency of receiver reports.
16
Real-time Streaming Protocol (RTSP)
Supports interactive applications
Out-of-band channel
17
100-Mbps Ethernet
100-Mbps Ethernet
Variable fill rate x(t)Buffer
Constant drain rate d
Stored Media Server
UncompressRemove Jitter
Forward Error CorrectionGUI
Multimedia Client
Multimedia Player
MultimediaDatabase
ServerThread(one per
clientprocess
)
DatabaseAccess
DataStreaming
RTSP
Multimedia Server Process
Setup PlayMedia Stream Pause Teardown
Out-of-Band Client-Server Interactions UsingRTSP
In-BandCommunication
Using RTP
18
Data compression
Sender
CompressionInformation
Source
Receiver
Uncompression Player
19
Data compression
Text compression
Still image compression
Audio and Video compression
20
Loseless compression
Differential encoding – amplitudes of consecutive samples differ only slightly.
Entropy encoding – removes the redundancy based upon the entropyRun Length EncodingStatistical Encoding
21
Text Compression
Huffman EncodingProduces optimal results only if the probability of
occurrence of individual characters is a power of ½.
Static Huffman EncodingAdaptive Huffman Encoding
Lemplel-Ziv
22
A (0.5)B (0.25)C (0.125)D (0.0625)E (0.0156)F (0.0156)G (0.0156) 1H (0.0156) 0
A (0.5)B (0.25)C (0.125)D (0.0625) (0.0312)E (0.0156) 1F (0.0156) 0
A (0.5)B (0.25)C (0.125)D (0.0625) (0.0312) 1 (0.0312) 0
A (0.5)B (0.25)C (0.125)D (0.0625) 1 (0.0625) 0
L8 L7
L6
L5
A (0.5)B (0.25)C (0.125) 1 (0.125) 0
L3
A (0.5)B (0.25) 1 (0.25) 0 L4
A (0.5) 1 (0.5) 0
L2
ABCDEFGH
1010010001000001000000000011000010
0 1
1.0
0.5 A 0.5
B 0.250.25
0 1
0 1
C 0.1250.125
D 0.061250.06125
0
0
1
1
0.030625
H 0.01565 G 0.01565
0.030625
1100
E 0.01565F 0.01565
23
0Ef 0
Ef 0
0 1
a 1
send a
1
11
0
0a 1
Ef 0 l 1
send l
Ef 0 ; a 1
Ef 0; l 1; 1; a 1
l
a
e0
0
0
Ef 0 e 1
l 1
a 11
1
11
2
send e
Ef 0; e 1; 1; l 1; 2; a 1
Ef 0; e 1; 1; l 1; a 1; 2
sort list by count
Ef 0 e 1
11
1
12a 1
0
0
0l 1
a send " "
a 2 2
Ef 0 e 1
1
1
1
1l 1
0
0
0
Ef 0; e 1; 1; l 1; a 2; 2
j
Ef 0
e 1
j 1
0
0
0
01
1
1
1
13a 2
l 12
send j
Ef 0; j 1; 1; e 1; 2; l 1; a 2; 3
Ef 0; j 1; 1; e 1; l 1; 2; a 2; 3
sort list by count
Ef 0 j 1
1
3a 2
l 1 2
1 e 1
1
1
1
0
0
0
0
24
Lempel-Ziv
Construct a dictionary consisting of all the substrings in the input string
Instead of transmitting a substring we transmit the index of the substring in the dictionary.
Lempel-Ziv-Welsh the dictionary is constructed dynamically.
25
Compression factor for LZ
N # of characters in the text
n bits/character
L average length of a substring
D # of entries in the dictionary D=2d
compression = (N x n) / (N/L x d) = ( n x L) / d
26
Still image compression
GIF – Graphics Interchange FormatReduces the number of colors in the image from
224 to 28
Selects the 256 colors that match best the colors in the picture and builds a local color table
Instead of sending 24- bit pixels we send 8-bit pixels that are indexes in the local color table
JPEG – Joint Photographic Experts Group
27
JPEG
SourceImage
CompressedImage
Entropy Encoding
Vectoring
RLE
DiffEncoding
HuffmanEncoding
BlockPreparation
DCT Quantization