Presentation is loading. Please wait.

Presentation is loading. Please wait.

CS 414 - Spring 2012 CS 414 – Multimedia Systems Design Lecture 29 – Buffer Management (Part 2) Klara Nahrstedt Spring 2012.

Similar presentations


Presentation on theme: "CS 414 - Spring 2012 CS 414 – Multimedia Systems Design Lecture 29 – Buffer Management (Part 2) Klara Nahrstedt Spring 2012."— Presentation transcript:

1 CS 414 - Spring 2012 CS 414 – Multimedia Systems Design Lecture 29 – Buffer Management (Part 2) Klara Nahrstedt Spring 2012

2 Administrative MP2 posted MP2 Deadline – April 7, Saturday, 5pm. CS 414 - Spring 2012

3 Covered Aspects of Multimedia Image/Video Capture Media Server Storage Transmission Compression Processing Audio/Video Presentation Playback Audio/Video Perception/ Playback Audio Information Representation Transmission Audio Capture A/V Playback Image/Video Information Representation CS 414 - Spring 2012

4 Multimedia Protocols: Layered Code CS 414 - Spring 2012 Sampling/Encoding Streaming Application Real-time Transport Protocol (Packetization/ And Segmentation) UDP IP Ethernet Segmentation Decoding/Playout Streaming Application Real-time Transport Protocol (De-Packetization And Re-assembly) UDP IP Ethernet Re-assembly Reassembly SENDER RECEIVER NETWORK S T3 T1 T2 Multicast T1 T2 T3 Multi-Traget S T Unicast

5 Sender/Receiver Curves for Transmission of Voice over Packet-switched network may cause packet losses CS 414 - Spring 2012 p s (t) b s (t)r(t) p r( t) bytes Late loss

6 Protocol Requirements on Buffer Management (Summary) Protocol Requirement: Segmentation Splitting of service data units (SDU) Identification of each split SDU Protocol Requirement: Reassembly Linking memory to form one buffer Protocol Requirement: Retransmission (in case of TCP) Maintain logical copy of buffer to store SDU for possible retransmission Protocol Requirement: Multicast Keep one buffer for all recipients and use multicast group address Protocol Requirement: Multi-target  Keep one memory segment common to all buffers CS 414 - Spring 2012

7 Buffer Management Techniques for Layered Code in Multimedia Protocol Stack Data Copying Offset Management Scatter-Gather CS 414 - Spring 2012

8 Data Copying CS 414 - Spring 2012 Transport Service Entity (UDP) Copy data Network Service Entity (IP) Buffer for UDP Datagram Kernel User space RTP Streaming Service Buffer for RTP Protocol Data Unit Buffer for IP Datagram Buffer Management System at Receiver Copy data

9 Data Copying and Offset Management CS 414 - Spring 2012 PCI1Data PCI1 DataPCI2 App RTP UDP DATA COPYING 1. app 2. PCI1 added by RTP 3. PCI2 added by UDP 1. data2. PCI13. PCI2 OFFSET MANAGMENT Buffer Management: Assign as large buffer as data + all headers of the protocols require Problems:??? Buffer Management: Copy data and PCIs between protocol layers

10 Scatter-Gather CS 414 - Spring 2012 Scatter/Gather Table Structure DATA DataPTR1 PCI1 PTR2 PCI2 PTR3 Application Buffer Space RTP Buffer Space UDP Buffer Kernel Space Problems: ??? Buffer Management: Establish scatter/gather Table structure across all protocol layers to keep Track where payload (data) and control info (PCIs) Are located

11 Comparison CS 414 - Spring 2012 Data CopyingOffsetScatter/Gather Memory BWHighLow CPU BWHighLow Memory Usage per Layer Optimal for individual protocol layer because exact amount of space will be allocated High for application protocol because it must allocate space more than it needs Compromise, segments are sized depending on requirements Are Protocol Requirements without copying satisfied? NANo, segmentation needs copying Mostly yes (one copy and segmentation must be done when data leaves node)

12 Client-Server Systems: Distributed Application Code CS 414 - Spring 2012 Read encoded frames from VOD Disk Packetization Protocol Stack Processing network De-Packetization Protocol Stack Processing Decoderplayout VOD Server VOD Client

13 Client/Server Video-on-Demand System CS 414 - Spring 2011

14 VOD Retrieval Transmission and Playout Curves CS 414 - Spring 2012 time bytes Retrieval curve From disk Sending Curve from VOD server Receiving Curve at VOD Client Playout Curve At VOD Client Playout buffers

15 Playout Buffers Goal: face effects caused by Network delay, delay jitter, packet loss on continuous media streams  By using QoS-aware network technologies (RSVP, DiffServ, ATM, …) not widely adapted  By using adaptive playout control techniques Face unpredictability of IP networks by compensating for variable network delays and jitters experienced during the transmission of media packets CS 414 - Spring 2012

16 Adaptive Playout Control Mechanisms Delay jitter is smoothed away by  Employing playout buffer at the receiver  Dynamically enqueueing packets into it Playout buffer  Delays received packets for some time to allow smooth media packet playout rate,  Absorbs negative effects introduced by delay jitter  Must be adaptive since delay jitter on Internet may vary significantly with time. CS 414 - Spring 2012

17 Playout Delays CS 414 - Spring 2012 Small Playout DelayLarge Playout Delay

18 Buffer Management Techniques for VOD Client Consider time of buffer setup  Fixed Buffer Technique  Dynamic Buffer Technique Consider size of buffer  MinBuf  MaxBuf CS 414 - Spring 2012

19 Buffer Management Strategies Clients need buffers for VOD (Video-on- Demand) application to smooth out traffic jitters Buffer management strategies balance bits in transit (buffer size and bits in channel) Fixed Strategy (non-adaptive) and dynamic (adaptive) CS 414 - Spring 2012

20 Buffer Management Strategies Fixed buffer strategy  Static buffer allocation during multimedia call setup phase  Static buffer allocation does not change during run-time Dynamic buffer strategy  Elastic buffer allocation, i.e., allocate buffers during multimedia call setup, but change them during run-time CS 414 - Spring 2012

21 Buffering Strategies at VOD Client Minbuf - minimum buffering strategy  Minbuf minimizes buffering requirements at VOD client, but makes more demands on network (throughput and delay guarantees) Maxbuf – maximum buffering strategy  Maxbuf buffers more than one unit of information and eases QoS guarantees demands on network  Buffering only up to a limit (Buf max ) CS 414 - Spring 2012

22 Conclusion Need buffering consideration in layered code of multimedia protocol stack  Data copying  Offset management  Scatter-gather Need buffering consideration in distributed code of multimedia applications, e.g., Video- on-Demand (VOD) service  Buffering at the VOD client side  Some buffering needed also at VOD Server side CS 414 - Spring 2012


Download ppt "CS 414 - Spring 2012 CS 414 – Multimedia Systems Design Lecture 29 – Buffer Management (Part 2) Klara Nahrstedt Spring 2012."

Similar presentations


Ads by Google