MULTIMEDIA CONCEPTS Multimedia Concepts 1 MULTIMEDIA CONCEPTS Topics

  • Slides: 64
Download presentation
MULTIMEDIA CONCEPTS Multimedia Concepts 1

MULTIMEDIA CONCEPTS Multimedia Concepts 1

MULTIMEDIA CONCEPTS Topics § Multimedia Basic Terms § Multimedia Compression/Decompression § Multimedia Protocols 2

MULTIMEDIA CONCEPTS Topics § Multimedia Basic Terms § Multimedia Compression/Decompression § Multimedia Protocols 2

MULTIMEDIA CONCEPTS Basic Terms § Multimedia Definition Ø The term multimedia usually implies that

MULTIMEDIA CONCEPTS Basic Terms § Multimedia Definition Ø The term multimedia usually implies that at least one of text ( structured/unstructured, hypertext, etc), graphics (drawings), or image (discrete media) is associated with either audio or motion video information (continuous media). 3

MULTIMEDIA CONCEPTS Basic Terms § Multimedia streaming Ø Multimedia streaming is the overlapping the

MULTIMEDIA CONCEPTS Basic Terms § Multimedia streaming Ø Multimedia streaming is the overlapping the playout of the data at the receiver with the transmission by the sender. v A video stream consists of a sequence of images or frames. • A frame consists of a grid of pixels. (Table 1) v An audio stream consists of a sequence of audio samples. 4

MULTIMEDIA CONCEPTS Basic Terms Term Pixel Frame Stream Session Presentation Definition Picture element Two-dimensional

MULTIMEDIA CONCEPTS Basic Terms Term Pixel Frame Stream Session Presentation Definition Picture element Two-dimensional grid of pixels Sequence of frames over time Synchronized set of streams Set of multimedia sessions Table 1. Hierarchy of multimedia content. 5

MULTIMEDIA CONCEPTS Basic Terms § The advantage of streaming is that it can enable

MULTIMEDIA CONCEPTS Basic Terms § The advantage of streaming is that it can enable easier access to multimedia resources. § Another possibility is the integration of video and audio with other web-based applications, such as chat and other realtime collaboration tools. 6

MULTIMEDIA CONCEPTS Basic Terms § Streaming vs. downloading § What Is The Difference Between

MULTIMEDIA CONCEPTS Basic Terms § Streaming vs. downloading § What Is The Difference Between Downloading and Streaming? ØWhen you download a video, you have to copy the entire file to your hard disk before you can play it. 7

MULTIMEDIA CONCEPTS Basic Terms ØWhen the video is streamed, there is a small wait

MULTIMEDIA CONCEPTS Basic Terms ØWhen the video is streamed, there is a small wait as the stream 'buffers' but there is no need to save the file. ØStreaming is the act of sending media files (audio and/or video) over the Internet from one computer to another computer so that the media plays as it is being delivered. 8

MULTIMEDIA CONCEPTS Basic Terms § Multimedia Streaming • Multicast capable • More Robust •

MULTIMEDIA CONCEPTS Basic Terms § Multimedia Streaming • Multicast capable • More Robust • Access to Storage • Relieves Web Server Audio Video Animation Proprietary Format Media Encoding Media Server Send Request to Media Server Web Server • Standalone player • Java based player • Browser plug-in player • Appliance Send Stream To Clients • Decode • Buffer • Sync. Send Request To Servers Figure 2. To hear or view a media file without downloading it 9

MULTIMEDIA CONCEPTS Basic Terms § A media stream proceeds through the following stages before

MULTIMEDIA CONCEPTS Basic Terms § A media stream proceeds through the following stages before it is displayed to a recipient: Ø Capturing v The audio or video stream must be captured from an analog device, such as a microphone or a video camera, and converting to a digital form. v 25 fps (frame per second) for video and 16 bit for audio is suitable. 10

MULTIMEDIA CONCEPTS Basic Terms Ø Encoding v An encoder converts the raw digital data

MULTIMEDIA CONCEPTS Basic Terms Ø Encoding v An encoder converts the raw digital data into a particular audio or video format. Ø Storing v A server may store the encoded stream for future transmission. Ø Delivering v The stream is transmitted to one or more recipients. A live stream may be transmitted as it is captured and encoded, whereas a prerecorded stream is transmitted by a server. 11

MULTIMEDIA CONCEPTS Basic Terms Ø Decoding v The receiver decodes and displays the data

MULTIMEDIA CONCEPTS Basic Terms Ø Decoding v The receiver decodes and displays the data as they arrive. Alternatively, the receiver may store the entire stream before initiating playback. (Figure 3) 12

MULTIMEDIA CONCEPTS Basic Terms Figure 3. Capturing Video 13

MULTIMEDIA CONCEPTS Basic Terms Figure 3. Capturing Video 13

MULTIMEDIA CONCEPTS Basic Terms § There are two different types of streaming: Ø Progressive

MULTIMEDIA CONCEPTS Basic Terms § There are two different types of streaming: Ø Progressive download v The client begins playback of the multimedia file as it is delivered. The file is ultimately stored on the client computer. v Use standard web server v Quality is better than real-time streaming Ø Real-time streaming v The multimedia file is delivered to the client computer but the file is not stored on the client computer. v Require a special streaming server 14

MULTIMEDIA CONCEPTS Basic Terms § two different types of real-time streaming: Ø Live streaming

MULTIMEDIA CONCEPTS Basic Terms § two different types of real-time streaming: Ø Live streaming v used to deliver a live event while it is occurring. Examples: live soccer game, live concerts, live radio, and videoconferences. Ø On-demand streaming v used to deliver archived media streams. Examples: video clips, movies, and lectures. 15

MULTIMEDIA CONCEPTS Basic Terms § Why Streaming Media? Ø No waiting for complete downloads.

MULTIMEDIA CONCEPTS Basic Terms § Why Streaming Media? Ø No waiting for complete downloads. Ø Streamed files are not written to disk. Ø Presentation of live events is possible. 16

MULTIMEDIA CONCEPTS Basic Terms § Major streaming formats Ø Microsoft Windows Media Ø Real

MULTIMEDIA CONCEPTS Basic Terms § Major streaming formats Ø Microsoft Windows Media Ø Real Networks Ø Apple Quicktime 17

MULTIMEDIA CONCEPTS Basic Terms § How does streaming work? Figure 4. Streaming media development

MULTIMEDIA CONCEPTS Basic Terms § How does streaming work? Figure 4. Streaming media development process 18

MULTIMEDIA CONCEPTS Basic Terms § How does streaming work? Figure 5. Streaming media playback

MULTIMEDIA CONCEPTS Basic Terms § How does streaming work? Figure 5. Streaming media playback 19

MULTIMEDIA CONCEPTS Basic Terms Figure 6. Streaming media from a conventional Web server 20

MULTIMEDIA CONCEPTS Basic Terms Figure 6. Streaming media from a conventional Web server 20

MULTIMEDIA CONCEPTS Basic Terms Figure 7. Realtime Streaming protocol 21

MULTIMEDIA CONCEPTS Basic Terms Figure 7. Realtime Streaming protocol 21

MULTIMEDIA CONCEPTS Basic Terms § RTSP States Ø SETUP - the server allocates resources

MULTIMEDIA CONCEPTS Basic Terms § RTSP States Ø SETUP - the server allocates resources for a client session. Ø PLAY - the server delivers a stream to a client session. Ø PAUSE - the server suspends delivery of a stream. Ø TEARDOWN - the server breaks down the connection and releases the resources allocated for the session. 22

MULTIMEDIA CONCEPTS Basic Terms § RTSP State Machine Figure 8. RTSP state machihne 23

MULTIMEDIA CONCEPTS Basic Terms § RTSP State Machine Figure 8. RTSP state machihne 23

MULTIMEDIA CONCEPTS Basic Terms RTSP operation 24

MULTIMEDIA CONCEPTS Basic Terms RTSP operation 24

MULTIMEDIA CONCEPTS Basic Terms § Clip Ø Clip is a media file that contains

MULTIMEDIA CONCEPTS Basic Terms § Clip Ø Clip is a media file that contains audio, video, or both. 25

MULTIMEDIA CONCEPTS Basic Terms § Webcast Ø A webcast uses streaming media technology to

MULTIMEDIA CONCEPTS Basic Terms § Webcast Ø A webcast uses streaming media technology to take a single content source and distribute it to many simultaneous listeners/viewers by broadcasting over the Internet. 26

MULTIMEDIA CONCEPTS Basic Terms § Three general methods for delivering content from a server

MULTIMEDIA CONCEPTS Basic Terms § Three general methods for delivering content from a server to a client across a network: Ø Unicasting v The server delivers the content to a single client. Ø Broadcasting v The server delivers the content to all clients, regardless whether they want the content or not. Ø Multicasting v The server delivers the content to a group of receivers who indicate they wish to receive 27 the content.

MULTIMEDIA CONCEPTS Basic Terms § Broadcasting Ø Broadcast means a piece of information is

MULTIMEDIA CONCEPTS Basic Terms § Broadcasting Ø Broadcast means a piece of information is sent or transmitted from one point to all other points. Ø There is just one sender, but the information is simultaneously sent to all connected receivers. Ø In telecommunications, broadcasting means propagation of a flow of information from one source to all potential recipients. 28

MULTIMEDIA CONCEPTS Basic Terms § Broadcasting Ø In networking, a distinction is made between

MULTIMEDIA CONCEPTS Basic Terms § Broadcasting Ø In networking, a distinction is made between broadcasting and multicasting. v Broadcasting sends a message to everyone on the network. v Multicasting sends a message to a select list of recipients. 29

MULTIMEDIA CONCEPTS Basic Terms Figure 10. Unicast delivering 30

MULTIMEDIA CONCEPTS Basic Terms Figure 10. Unicast delivering 30

MULTIMEDIA CONCEPTS Basic Terms Figure 11. Multicast delivering 31

MULTIMEDIA CONCEPTS Basic Terms Figure 11. Multicast delivering 31

MULTIMEDIA CONCEPTS Basic Terms § Unicast/Multicast Unicast Host Router Multicast Host Router Figure 12.

MULTIMEDIA CONCEPTS Basic Terms § Unicast/Multicast Unicast Host Router Multicast Host Router Figure 12. Unicast/Multicast delivering 32

MULTIMEDIA CONCEPTS Basic Terms § Bit rate Ø Bit rate is amount of data

MULTIMEDIA CONCEPTS Basic Terms § Bit rate Ø Bit rate is amount of data that can be carried from one point to another in a given time period (usually a second). Ø Bit rate is sometimes called data rate or transfer rate or bandwidth. § Multiple Bit Rate Encoding Ø Combine several streams with different bit rate into a single file Ø The appropriate bit rate stream is automatically selected (Figure 13) 33

MULTIMEDIA CONCEPTS Basic Terms Figure 13. Multiple bit rate encoding 34

MULTIMEDIA CONCEPTS Basic Terms Figure 13. Multiple bit rate encoding 34

MULTIMEDIA CONCEPTS Basic Terms § Aspect Ratio Ø This is the ratio of width

MULTIMEDIA CONCEPTS Basic Terms § Aspect Ratio Ø This is the ratio of width to height that the encoded video will be. Ø This information is present in the output video stream and used by the decoder to display the video at the correct aspect ratio. Ø The computer display is designed for an aspect ratio of 1. 33: 1, which means that the width of the display area is only 1. 33 times the height, almost square. 35

MULTIMEDIA CONCEPTS Basic Terms § Frame Ø Frame means one still picture. Ø By

MULTIMEDIA CONCEPTS Basic Terms § Frame Ø Frame means one still picture. Ø By changing still pictures (frames) quickly, human eye "thinks" that the video is smooth and can't separate pictures from each others and instead sees smooth video. 36

MULTIMEDIA CONCEPTS Basic Terms § Frame rate Ø Frame rate is the number of

MULTIMEDIA CONCEPTS Basic Terms § Frame rate Ø Frame rate is the number of video frames (complete pictures) that will be presented to the viewer each second. Ø Human eye can sees smooth video with the frame rate more than ~24 fps (frames per second). Ø In American TV system, NTSC, the frame rate is approximately 29. 97 fps. Ø In European PAL system the frame rate is 25 fps. 37

MULTIMEDIA CONCEPTS Basic Terms § Frame Buffer Ø Frame buffer is a special memory

MULTIMEDIA CONCEPTS Basic Terms § Frame Buffer Ø Frame buffer is a special memory to hold the complete digital representation of the frame to be displayed on a computer screen. Ø The frame buffer is scanned line by the digital-to-analog converter system of the display. 38

MULTIMEDIA CONCEPTS Basic Terms § Color depth Ø Color depth or bit depth is

MULTIMEDIA CONCEPTS Basic Terms § Color depth Ø Color depth or bit depth is the number of bits used to represent the color of a single pixel in a bitmapped image or video frame buffer. Ø It is known as bits per pixel (bpp). Ø Higher color depth gives a broader range of distinct colors. (Table 2) 39

MULTIMEDIA CONCEPTS Basic Terms Bit-Depth Number of Colors 1 2 (monochrome) 2 4 (CGA)

MULTIMEDIA CONCEPTS Basic Terms Bit-Depth Number of Colors 1 2 (monochrome) 2 4 (CGA) 4 16 (EGA) 8 256 (VGA) 16 65, 536 (High Color, XGA) 24 16, 777, 216 (True Color, SVGA) 32 16, 777, 216 (True Color + Alpha Channel) Table 2. Color depth chart. 40

MULTIMEDIA CONCEPTS Basic Terms § Jitter Ø In transmission technology, jitter refers to the

MULTIMEDIA CONCEPTS Basic Terms § Jitter Ø In transmission technology, jitter refers to the variation of the delay generated by the transmission equipment. Ø In data communications, jitter refers to the variation over time of the network transit delay. 41

MULTIMEDIA CONCEPTS Multimedia Compression § § § Lossless compression Lossy compression Compression/Coding Standards Decompression

MULTIMEDIA CONCEPTS Multimedia Compression § § § Lossless compression Lossy compression Compression/Coding Standards Decompression Codec 42

MULTIMEDIA CONCEPTS Multimedia Compression § Compression is the process of eliminating redundant information to

MULTIMEDIA CONCEPTS Multimedia Compression § Compression is the process of eliminating redundant information to decrease file size. § Compression converts frames and pixels to mathematical algorithms that the computer can understand. § Decompression converts mathematical algorithms back to frames and pixels for playback. 43

MULTIMEDIA CONCEPTS Multimedia Compression § Two compression methods are: Ø Lossless compression • Run-Length

MULTIMEDIA CONCEPTS Multimedia Compression § Two compression methods are: Ø Lossless compression • Run-Length coding • Huffman coding • Arithmetic coding Ø Lossy compression • Transform coding 44

MULTIMEDIA CONCEPTS Lossless compression § Lossless compression retains all of the data of the

MULTIMEDIA CONCEPTS Lossless compression § Lossless compression retains all of the data of the original file as it's converted to a smaller file size. § In lossless compression the information is recovered without any alteration after the decompression stage. § When a lossless file is opened, algorithms restore all compressed information, creating a duplicate of the source file. 45

MULTIMEDIA CONCEPTS Lossless compression § It generally preferred for creating highquality or professional applications.

MULTIMEDIA CONCEPTS Lossless compression § It generally preferred for creating highquality or professional applications. § Lossless compression is applied where the accuracy of the information is essential, such as in medical imaging where it's important to retain fine detail. § Lossless compression is also called bitpreserving compression. 46

MULTIMEDIA CONCEPTS Lossy compression § Lossy compression refers to the case where the decompressed

MULTIMEDIA CONCEPTS Lossy compression § Lossy compression refers to the case where the decompressed information is different from the original uncompressed information. § With this kind of compression, some of the source file's information is discarded to conserve space. 47

MULTIMEDIA CONCEPTS Lossy compression § When the file is decompressed, this information is reconstructed

MULTIMEDIA CONCEPTS Lossy compression § When the file is decompressed, this information is reconstructed through algorithms. § This method results in some loss of sound quality or image detail when compared to the original. § This mode is suitable for most continuous media such as sound and motion video as well as for many images. 48

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG Standards Ø MPEG standards developed and managed

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG Standards Ø MPEG standards developed and managed by Motion Picture Experts Group (MPEG) v v v MPEG-1: VCD MPEG-2: DVD, HDTV MPEG-4: Content-based video coding MPEG-7: Multimedia indexing and retrieval MPEG-21: Multimedia delivery and consumption 49

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG-1 Ø Released in 1992 Ø A standard

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG-1 Ø Released in 1992 Ø A standard for coded representation of • Moving pictures • Audio • Combination of above Ø Typical application – video CD (VCD) 50

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG-2 Standard Ø Released in 1994 Ø A

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG-2 Standard Ø Released in 1994 Ø A standard to provideo quality not lower than NTSC/PAL with bit rates target between 2 -10 Mbit/s Ø Applications v v Digital cable TV distribution Networked database service via ATM Digital video tape recorder (VTR) Satellite and terrestrial digital broadcasting distribution Ø It also supports HDTV applications, and so preemptied MPEG-3 standard 51

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG-4 Standard Ø First released in 1998, and

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG-4 Standard Ø First released in 1998, and targeted for content-based multimedia applications and low bit-rate video coding. Ø Algorithms and tools for coding and flexible representation of audio/video to meet the challenges of multimedia applications. Ø The objective of low bit-rate video coding was later accomplished by H. 264, the convergence of ITU-T H. 263 and MPEG-2. 52

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG-7 Ø First release in 2001 Ø Official

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG-7 Ø First release in 2001 Ø Official name: Multimedia Content Description Interface Ø Objective: v To allow efficient search for multimedia content using standardized descriptors Ø The main research issues: v Optimum search engine v Feature analysis & query design 53

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG-21 Standard Ø Aim at defining a normative

MULTIMEDIA CONCEPTS Compression/Coding Standards § The MPEG-21 Standard Ø Aim at defining a normative open framework for multimedia delivery and consumption for use by all the players in the delivery and consumption chain. 54

MULTIMEDIA CONCEPTS Decompression § Decompression is the process by which compressed information is expanded

MULTIMEDIA CONCEPTS Decompression § Decompression is the process by which compressed information is expanded by addition of the redundant information eliminated at the compression stage. § After decompression, the resulting information may be identical to the original – lossless compression – or be different – lossy compression. 55

MULTIMEDIA CONCEPTS Codec § Codec stands for Coder/Decoder or Compression/Decompression. § Codec is a

MULTIMEDIA CONCEPTS Codec § Codec stands for Coder/Decoder or Compression/Decompression. § Codec is a piece of software or a driver that is mostly for compression to reduce file size but may also do some formatting. § Compression is the primary function of the Codec. 56

MULTIMEDIA CONCEPTS Codec § With codec, your system recognizes the encoded video/audio format and

MULTIMEDIA CONCEPTS Codec § With codec, your system recognizes the encoded video/audio format and allows you to play (decode) the audio/video file in a particular format. 57

MULTIMEDIA CONCEPTS Codec Examples § Video Ø MPEG 1, MPEG 2, DIVX, WMV(WINDOWS MEDIA

MULTIMEDIA CONCEPTS Codec Examples § Video Ø MPEG 1, MPEG 2, DIVX, WMV(WINDOWS MEDIA VIDEO), MPEG 4 -H 264, Real. Video § Audio Ø MP 3, ATRAC, AAC, WMA (WINDOWS MEDIA AUDIO), DTS, Real. Audio § Image Ø JPEG, JPEG 2000, PNG, GIF § Data Ø ZIP, STUFFIT 58

MULTIMEDIA CONCEPTS Multimedia Protocols § TCP (Transmission Control Protocol) § UDP (User Datagram Protocol)

MULTIMEDIA CONCEPTS Multimedia Protocols § TCP (Transmission Control Protocol) § UDP (User Datagram Protocol) § RTP (Real-time Transport Protocol) § RSVP (Resource Re. Ser. Vation Protocol) (Table 3) 59

MULTIMEDIA CONCEPTS Multimedia Protocols Network Protocol Advantage Disadvantage TCP · Dominate protocol for data

MULTIMEDIA CONCEPTS Multimedia Protocols Network Protocol Advantage Disadvantage TCP · Dominate protocol for data transfer of data over the Internet · Streaming through firewall · Reliable · Typically need large buffer to handle data rate variation · Loss recovery needs retransmission causing further jitter or skew · No support for multicast UDP · Suitable for streaming · Allows packet drops; if packets arrive late or damaged, streaming will continue · No retransmission needed · Many network firewalls block UDP data · Need error concealment for video packet loss · No support for congestion control · Cannot be played using popular stream players such as Quick. Time RTP/RTCP · Support real-time transmission · Provide timing reconstruction, loss detection, security and content identification · Allows retrieval of very interesting network statistics · No guarantee for Qo. S · Header is larger than UDP · More complicated that UDP · No support for congestion control RSVP · Reliable connection · Receiver can obtain different levels of service · Complicated request mechanism · Receivers may experience random packet loss for small reservation 60 Table 3. Multimedia protocols.

MULTIMEDIA CONCEPTS References 1) B. Krishnamurthy, J. Rexford. “Web Protocols and Practice”, 2001 2)

MULTIMEDIA CONCEPTS References 1) B. Krishnamurthy, J. Rexford. “Web Protocols and Practice”, 2001 2) A. Silberschatz, P. Garvin, G. Gange. “ operating system concepts”, 2005 3) http: //www. micc. unifi. it/delbimbo/documents/prog_prod _multimediale/2 4) H. Sun, A Vetro, J. Xin. “ An Overview of Scalable Video Streaming”. 2007 5) Z. Li and M. S. Drew. “Fundamentals of Multimedia”, Prentice-Hall 2004 6) R. Steinmetz, K. Nahrstedt, “Multimedia: Computing, Communications and Applications”, Prentice-Hall 1995 61

MULTIMEDIA CONCEPTS References 7) T. Vaughan, “Multimedia: Making it Work, 7 th Edition”, Mc.

MULTIMEDIA CONCEPTS References 7) T. Vaughan, “Multimedia: Making it Work, 7 th Edition”, Mc. Graw-Hill College 2006 8) L. Guan, S. Y. Kung, J. Larsen “Multimedia image and video processing” 62

MULTIMEDIA CONCEPTS References Image Compression JPEG: http: //www. faqs. org/faqs/jpeg-faq/part 1/ JPEG: http: //en.

MULTIMEDIA CONCEPTS References Image Compression JPEG: http: //www. faqs. org/faqs/jpeg-faq/part 1/ JPEG: http: //en. wikipedia. org/wiki/JPEG Video Compression MPEG-4 pt. 2: http: //en. wikipedia. org/wiki/MPEG-4_Part_2 MPEG-4 pt. 10/H. 264/AVC: http: //en. wikipedia. org/wiki/H. 264/MPEG 4_AVC File Formats General info: http: //en. wikipedia. org/wiki/File_format Containers: http: //en. wikipedia. org/wiki/Container_format MPEG-4 pt. 14: http: //en. wikipedia. org/wiki/. m 4 a Codec list: http: //www. fourcc. org/ Audio MP 3: http: //en. wikipedia. org/wiki/MP 3 63

MULTIMEDIA CONCEPTS References DCT Basis Function Image: http: //en. wikipedia. org/wiki/Image: Dctjpeg. png, GNU

MULTIMEDIA CONCEPTS References DCT Basis Function Image: http: //en. wikipedia. org/wiki/Image: Dctjpeg. png, GNU licensed JPEG Example Image: http: //en. wikipedia. org/wiki/Image: Phalaenopsis_JPEG. jpg , by Ilmari Karonon at Wikipedia, Creative Commons Attribution-Share. Alike 2. 5 License MP 3 File Image: http: //en. wikipedia. org/wiki/Image: Mp 3 filestructure. jpg 64