mpeg & mp3 -supplement - from “ graham mcallister - nortel networks ”

25
MPEG & MP3 MPEG & MP3 - supplement supplement - from “ from “ Graham McAllister - Nortel Graham McAllister - Nortel Networks Networks

Upload: sage-moores

Post on 01-Apr-2015

217 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MPEG & MP3MPEG & MP3MPEG & MP3MPEG & MP3-supplement supplement

- from “from “Graham McAllister - Nortel NetworksGraham McAllister - Nortel Networks””

Page 2: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

Technique Compression Ratio

When?

Huffman 1.5-2:1 1952

RLE 4-10:1 1966

LZW 2-10:1 1977&84

Quadtree 2:1 1980

VQ 10:1 1984

Directional Filtering

10-40:1 1985

Fractals 10-1000:1 1988

MPEG-1 10-100:1 1993

Surface Methods

10-50:1 1995

MPEG-2 10-200:1 1995

MPEG-4 10-500:1 1999

time

Page 3: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MPEG Today• MPEG-2

– Super-set of MPEG-1– Rates up to 10 Mbps (720x486)– Can do HDTV (no MPEG-3)

• MPEG-4– Around Objects, not Frames– Lower bandwidth

• MPEG-7– Not (yet) a standard– Allows content-description (ease of searching)

• MPEG-21• MP3

– For audio– MPEG-1 Layer-3

Page 4: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

Digital video formats

MPEG / MJPEGFiles with a .mpg extension

Apple QuickTimeFiles with a .mov or .qt extension

Microsoft AVIFiles with a .avi extension

Real PlayerFiles with a .rm extension

Page 5: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”
Page 6: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”
Page 7: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

1. Image Sequence Compression

• Uses Inter-frame encoding

• Also known an image sequence or temporal coding

Page 8: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

Temporal Redundancy Reduction

Page 9: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MPEG Process• How does it work?• 1. Sub-sample

• Reduces data by around 50%

R G B Y U V

luminance

Page 10: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MPEG Process II• 2. Motion Detection – on luminance block

only• three types of frame …• I Frames – intra-coded• P Frames – prediction from previous frame• B frames – use bi-directional prediction

1

I

2

B

3

B

4

P

5

B

6

P

7

B

8

I

Page 11: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

• Example sequence transmitted as I P B B I B B

Frame 1 Frame 2 Frame 3 Frame 4 Frame 5 Frame 6 Frame 7

I frame B frame B frame P frame B frame B frame I frame

MPEGcompression

Forwardprediction

Bidirectionalprediction

Compressedstream

Inputstream

Page 12: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

Motion Compensation• I-Frame

– Independently reconstructed

• P-Frame– Forward predicted

from the last I-Frame or P-Frame

• B-Frame– forward predicted

and backward predicted from the last/next I-frame or P-frame

Transmitted as - I P B B B P B B B

Page 13: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

Motion Prediction

Page 14: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

Motion Estimation

Page 15: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

Motion Estimation (cont’d)

Page 16: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

Temporal Redundancy Reduction

• I frames are independently encoded• P frames are based on previous I, P frames• B frames are based on previous and following I and P frames

– In case something is uncovered

Page 17: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MPEG Process III - Schematic

Image Sequences

RGBTo

YUV

Motion Estimation DCT

QuantizeRLEVLCOutput Buffer

No compression achieved

Page 18: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MPEG-1 & MPEG-2• MPEG-1

– Designed for video playback at 150KB/s - single speed CD-ROM

– Used in VCD technology

• MPEG-2– Much higher bandwidth – 3MB/s– DVD technology

Page 19: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MPEG-4• Very different from previous generations

• Aimed at low-bandwidth applications – at upper end, good enough for digital TV

• Digital Camcorders

Page 20: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MPEG-4 II - Meshes• 2-D animated meshes

• Textures mapped onto meshes• Store vertices of mesh and movement parameters

Page 21: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MPEG-4 III - Sprites• MPEG-4 is object based – state of the art

• Panoramic images – massive compression ratios – 1000:1

Page 22: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

2. Audio Compression• Techniques from image compression can

be used– Huffman encodes output– DCT

• MP3 – huge!!!!

Page 23: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MP3 – MPEG-1 Layer 3• 1. Minimal Audition Threshold

– Don’t store anything under 5Khz

• 2. Masking Effect– Uses psychoacoustic model of the ear– Don’t store quiet and loud noises

simultaneously

Page 24: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MP3 II• 3. Joint Stereo (JS) coding

– 1. Intensity Stereo (IS)• Ear unable to locate some frequencies – bass• Store signal in mono + minimum for spatialization

– 2. Mid/Side (MS) Stereo• Used if left and right speakers are similar• Store middle (L+R) plus a side speaker (L or R)

e.g. L R

10 57 5Store:

Raw:Fewer bits

Decompress: 10 5

Page 25: MPEG & MP3 -supplement - from “ Graham McAllister - Nortel Networks ”

MP3 III - schematic