SlideShare uma empresa Scribd logo
1 de 37
compression
from production format to distribution format




         erik.luyten@dml.kuleuven.be
What's this ?




René Margritte: La Trahison des Images (1928-29)
Moving images !?
Temporal resolution



 2 images/second     5 images/second




12,5 images/second   25 images/second
A very small image
Spatial resolution




7 x 10 = 70                14 x 20 = 280
  28 x 40 = 1120             56 x 80 = 4480
    112 x 160 = 17920          224 x 320 = 71680
     448 x 640 = 309120
graylevel resolution



1 bit/ 2        2 bit/ 4    3 bit/ 8    4 bit/ 16




5 bit/ 32       6 bit/ 64   7 bit/128   8 bit/256
Creating colour: mixing light




RGB triangle     Red channel     Green channel     Blue channel




 3 x 8 bits    256 red steps   256 green steps   256 blue steps
Color resolution




24 bit color pallet   8 bit color pallet   8 bit optimized pallet   4 bit color pallet
                                                                    4 bit color pallet
244 KB file           28 KB file           28 KB file               No “dithering”
                                                                    16 KB file
Video signal(uncompressed)
                 768 pixels




                                         Each pixel has 3 values: (3 bytes)
          25 images/second               • Red: 256 steps (1 byte)
                                         • Green: 256 steps (1 byte)
                                         • Blue: 256 steps (1 byte)



Datarate for the RGB video signal:
768(pix) x 576(lines) x 3(byte) x 25(images)=32 MByte/sec(256    Mbit/sec)
Video signal (component)
                 720 pixels




                                     Each pixel has 3 values: (2 bytes)
                                     • Luminace(Y): 256 steps (1 byte)

            25 images/second         • Cr (R-Y): 128 steps (1/2 byte)
                                     • Cb (B-Y): 128 steps (1/2 byte)




Datarate for the component video signal:
720(pix) x 576(lines) x 2(byte) x 25(images)=20 MByte/sec(160
Mbit/sec)
Audio signal
 Sampling Rate: 44,1 kHz (CD)
 Bit Depth: 16 bit (65.536 steps)
 Stereo: x 2
 16 bit x 2 x 44.100 = 1.411.200 bps
                       1,4 Mbit/sec
Production systems normally use a sampling rate of
48 kHz
16 bit x 2 x 48.000 = 1.536.000 bps
Video distribution ?
                  1 second video: 32 Mbyte (256 Mbit/sec)
                  1 minute video: 1,9 GByte
                  1 hour video: 111 GByte

             Disk                                Network
 floppy disk = 0,05 seconds          Ethernet 100 Mbit/sec (shared) LAN
                                       1/2.5
 CD-rom = 20 seconds                 Ethernet 10 Mbit/sec (shared !) LAN
                                       1/25
 1 Gbyte hard disk = 32 seconds      ISDN lijn ( 2B + D) : 128Kbit/sec
                                       1/2000
 16 Gbyte array = 8 min 30 sec       Modem connection : 56 Kbit/sec
                                       1/4600
Compression techniques
Lossless
   No information loss
Lossy
   (Important) information is lost    (f.i. medical applications)


Intraframe (spatial compression)
  Compression within a single frame

Interframe (temporal compression)
  Compression between successive frames

Symmetric
   Coding and decoding equally processor intensive
Asymmetric
   Coding is more processor intensive than decoding
Lower datastream ?
320x240, 25fps, 24 bit   160x120 pix
43,2 Mbit/sec            10,4 Mbit/sec




12,5fps                  8 bit
21,6 Mbit/sec            14,4 Mbit/sec
Intraframe compression (in one frame)


                          Run Length Encoding
                         •without compression:
                           one line of 100 (white) pixels
                           100 x 3 bytes = 300 bytes
100                      • RLE compression
pixels
                           100 identical white pixels in a row
                           2 bytes: total amount of pixels involved
                           3 bytes for the colour information
                           2 + 3 = 5 bytes of info for 100 pixels
                         • Compression factor of 60:1
                           without information loss
Other Intraframe techniques
Discrete   Cosine Transformation
  •JPEG, MPEG, DV,…
  •Type of Fourier Transformation
  •Blocks of 8 x 8 pixels and/or 16 x 16
Wavelet    Compression
  •MPEG-4 (still image), JPEG2000
  •Improving image resolution as more data are received
Vector Quantization
Fractal Compression
Interframe compression




         Image 124




         Image 125
Interframe: MPEG (Moving Picture Expert Group)
GOP Group Of Pictures
  I-pictures: (Intra pictures) reference image with complete information for one
        frame (scene changes, ...)

    P-pictures: (Predicted pictures) images are “predicted” using the information in
        earlier I or P pictures.

    B-pictures: (Bi-directional predicted) pictures are recomposed from information
        in earlier or later I or P pictures. B-pictures are never used as reference for other
        images.




I     B       B       P        B      B       P       B       B        P       B       B        I
                            Group Of Pictures (GOP)
Movie Formats
File Format:
   Specifies how data are arranged in a file
      (interleaving video and audio)

Codec:
  Specifies how (image) data is compressed

Architecture:
  Synchronisation of different media components
     (video, audio, language tracks, text,…. tracks)
  Control for interactivity, alternate tracks,…
Movie Architectures
 QuickTime
 AVI
 Windows Media Player
 Real Media
 Flash ?
 MPEG-4
Media platform
           platform    distribution           cost            alternates                remarks
                                                          RTSP alternates        QTVR, text, midi, SMIL,..
                                         Player = free                           production and
           Mac        CD rom                              HTTP alternates
QuickTim   Windows    Download (HTTP)
                                         Pro = €30                               distribution
                                                          Mixed alternates
    e      (Linux)    Streaming (RTSP)
                                         Server= open
                                                          Skip prot.,instant -   H.264
                                         srce
                                                          on

                                         Player = free    RTSP alternates
           Windows
                      Streaming (RTSP)   Superpass=$13/   (Surestream            only distribution and
  Real     Mac
                      Download (HTTP)    m                techn.)                mainly for streaming
           Linux                         Server=payable   Dynamic

           Windows    Streaming ( )      Player=free                             Production anddistribution
Windows    (Mac)      Download (HTTP)
                                                          RTSP alternates
                                         Server=                                 Version 9 on windows
 Media                                                    Dynamic
           (Linux)    CD rom             Windows2003                             platform


 Flash
           Windows    CD rom
(Spark,                                  Player=free
           Mac        Download (HTTP)
                                         Server=€4759
                                                          ?                      H.264
 On2,      Linux      Streaming
 h264)
                                         Player=QT,                              Industrie standaard
                      Streaming (RTSP)
           Windows                       Real,…
                      Download (HTTP)                     scalable (in the       from handheld to HD
MPEG-4     Mac
                      CD rom
                                         Server=open
                                                          future)
                                         srce
           Linux
                      DVD, GSM, ….                                               H.264
File Formats
 DV
 MPEG-1
 MPEG-2
 MPEG-4
Codec’s
 Picture:
  •   Cinepak
  •   Indeo (Intel Indeo)
  •   H.261, H.263, H.264
  •   Sorenson
  •   M-JPEG
  •   MPEG-1, MPEG-2, MPEG-4
  •   DV

 Sound:
  •   IMA
  •   Qualcomm PureVoice, Qdesign Music,…
  •   MP3
  •   AAC (Advanced Audio Coding)
  •   WMA, RealAudio
MPEG-1, MPEG-2
                MPEG-4 difference
             MPEG-4 vs MPEG-1/2
                                                                                                          display
                                                                                                            and
  video                                                                                                   scaling




                                                                                          Decompression
                                     compression
             Composition
 subtitles   Rendering                                                                                    display
                and                                     transport                                           and
background                                                                                                scaling

 graphics



                                                      MPEG-4
                                                                                                          display




                                                                                    Scaling, Rendering
                                                                    Decompression
  video                       Bitmap stream           transport




                                                                                       Composition
                Compression




 subtitles                     ASCI code              transport                                           display




                                                                                            and
background                    Bitmap image            transport

 graphics                      Vector code            transport
Codec’s and bitrate
                  Web ?
                   Distribution codec’s                               Production codec’s
 56 kbit          200 kbit           1 Mbit             9 Mbit         25 Mbit          256 Mbit

                                                                                        uncompr.
                                     MPEG-1
                                               MPEG-2
                             H-261
     H-263
                Sorenson
                                                                        DV
 profile 0                              profile 1
                    MPEG-4                                            MPEG-4
                                               H.264
PIM, GSM, ...                                       HD distribution          Studio production
Comparing codecs
Cinepack :   4,2 Mbit/sec H-263 :    2 Mbit/sec MPEG 1:    1,8 Mbit/sec




Sorenson : 1,35 Mbit/sec MPEG-4 :   960 Kbit/sec H.264 :   502 Kbit/sec
Video to Computer
• Video recording
   • Interlaced, 25 frames - 50 fields per second
   • Restricted to 576 effective lines (PAL) and 3x4 picture
      aspect ratio.

• Computer image
   • Non-interlaced, 60 to 80 frames per second
   • No restrictions on picture format and aspect ratio
• De-interlacing of video material is desirable.
De-interlacing
                             Field 1
313                          Field 2
        1
314
        2
315
        3




623
      311
624
      312
625
      313
Delivery methods
 DVD, CD, USB stick,…

 Internet
  • Progressive download (HTTP, FTP)
        “file transport” type (TCP protocol)
        No data loss: resent lost packages
        No real-time events
        Complete file must be downloaded to allow random access.
        No special server needed (normal web service over http)
  • Streaming media (RTP)
        RTSP transport (UDP protocol)
        Lost data (probably) will not be recovered
        Real-time events possible
        “Random access” possibility (only needed fragments will be downloaded)
        Needs one or more(worldwide proxy delivery) streaming servers
(Progressive) download
                                        Web server



                                                               http://
 http://
                                                               www.avnet.kuleuven.be/
 www.avnet.kuleuven.be/
                                                               staalkaart/2004/video04.mov
 staalkaart/2004/video04.html




<object classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B"
codebase="http://www.apple.com/qtactivex/qtplugin.cab"
width="320" height="195">
<param name="loop" value="false">                                          File : video04.mov
<param name="cache" value="true">
<param name="src" value="video04.mov">                                     TCP/IP
<param name="autoplay" value="true">
<param name="controller" value="true">
<embed width="320" height="195"
pluginspage="http://www.apple.com/quicktime/download/"
src="video04.mov" type="video/quicktime" controller="true"
autoplay="true" cache="true" loop="false">
</object>
(video) podcasting
 Audio or audio/video distribution via internet
 Download file to client computer
 Mostly used for handheld devices
 Broadcast channel ---> Feeds
 Programs ---> Episodes
Podcast delivery: URL link
                                Web server AVNet

•Request for web pqge
•HTML with itpc link
•Request XML data
•XML file + startup iTunes

•Request for episodes
•HTTP download
episodes to iTunes




                             Client computer
RTSP streaming (or RTMP)
                                                     Web server                             Streaming server




http://                                                                                                    Datastream
www.avnet.kuleuven.be/                                                                                     RTP over UDP
Videotechniek/medatech.html




 <object classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B"
 width="384" height="304" codebase="http://www.apple.com/qtactivex/qtplugin.cab">
 <param name="autoplay" value="true">
 <param name="controller" value="true">
 <param name="pluginspage" value="http://www.apple.com/quicktime/download/indext.html">
 <param name="target" value="myself">
 <param name="type" value="video/quicktime">
 <param name="src" value="jaarverslag0304_384k.mov">
                                                                                          rtsp://escher.avnet.kuleuven.be/
 <param name="HREF"
 value="rtsp://escher.avnet.kuleuven.be/mediatechnologie/mediatech_384k.mov">
 <embed src="comtechn.mov" width="384" height="304" autoplay="true"
                                                                                          mediatechnologie/mediatech_384k.mov
 controller="true" border="0"
 pluginspage="http://www.apple.com/quicktime/download/indext.html"
 target="myself" type="video/quicktime"
 href="rtsp://escher.avnet.kuleuven.be/mediatechnologie/mediatech_384k.mov"></embed>
 </object>
Streaming - unicast
Streaming - multicast
HTTP streaming (iPhone, iPad,…)
 Ordinary webserver (Apache 2.2)
                                                   •   Apple HLS
 Segmented distribution of material.              •   Microsoft Smooth Streaming
     Material is chopped in 10 sec files          •   Adobe Flash HTTP Dynamic
     Index file with info on different segments       Streaming
     Distributed to client using http protocol

 VOD via h.264 compressed material
 Live streaming possible
     Latency 20-30 sec
     Stream segmenter

 #EXTM3U
 #EXT-X-MEDIA-SEQUENCE:0
 #EXT-X-TARGETDURATION:10
 #EXTINF:10,
 http://media.example.com/segment1.ts
 #EXTINF:10,
 http://media.example.com/segment2.ts
 #EXTINF:10,
 http://media.example.com/segment3.ts
 #EXT-X-ENDLIST

Mais conteúdo relacionado

Semelhante a Compression2011

Avlm 2009 Compression Erik Luyten
Avlm 2009  Compression   Erik LuytenAvlm 2009  Compression   Erik Luyten
Avlm 2009 Compression Erik Luytenavlm2009avnet
 
Week 4 LBSC 690 Information Technology
Week 4 LBSC 690 Information TechnologyWeek 4 LBSC 690 Information Technology
Week 4 LBSC 690 Information TechnologyVideoguy
 
PowerPoint 97
PowerPoint 97PowerPoint 97
PowerPoint 97Videoguy
 
Video Coding Standard
Video Coding StandardVideo Coding Standard
Video Coding StandardVideoguy
 
Commonly Used Image File Formats
Commonly Used Image File FormatsCommonly Used Image File Formats
Commonly Used Image File FormatsFatih Özlü
 
Preserving Audiovisual Materials (LIS 198-Digital Preservation)
Preserving Audiovisual Materials (LIS 198-Digital Preservation)Preserving Audiovisual Materials (LIS 198-Digital Preservation)
Preserving Audiovisual Materials (LIS 198-Digital Preservation)Roy Santos Necesario
 
Optimisation and Compression Intro
Optimisation and Compression IntroOptimisation and Compression Intro
Optimisation and Compression IntroJames Uren
 
Battle of the Codecs
Battle of the CodecsBattle of the Codecs
Battle of the CodecsJames Uren
 
Mm01 a vformat
Mm01 a vformatMm01 a vformat
Mm01 a vformatgotovikas
 
MPEG4 codec for Access Grid
MPEG4 codec for Access GridMPEG4 codec for Access Grid
MPEG4 codec for Access GridVideoguy
 
MPEG4 codec for Access Grid
MPEG4 codec for Access GridMPEG4 codec for Access Grid
MPEG4 codec for Access GridVideoguy
 
Introduction to computers
Introduction to computersIntroduction to computers
Introduction to computersVisualBee.com
 
Hollerback's Guide to Digital Video on the Web
Hollerback's Guide to Digital Video on the WebHollerback's Guide to Digital Video on the Web
Hollerback's Guide to Digital Video on the WebTeam Hollerback
 
From paper to screen: Putting maps on the web
From paper to screen:  Putting maps on the webFrom paper to screen:  Putting maps on the web
From paper to screen: Putting maps on the webPetr Pridal
 
Digital Image Processing and gis software systems
Digital Image Processing and gis software systemsDigital Image Processing and gis software systems
Digital Image Processing and gis software systemsNirmal Kumar
 
Digital Watchdog DW-VFHD46T Data Sheet
Digital Watchdog DW-VFHD46T Data SheetDigital Watchdog DW-VFHD46T Data Sheet
Digital Watchdog DW-VFHD46T Data SheetJMAC Supply
 

Semelhante a Compression2011 (20)

Avlm 2009 Compression Erik Luyten
Avlm 2009  Compression   Erik LuytenAvlm 2009  Compression   Erik Luyten
Avlm 2009 Compression Erik Luyten
 
Week 4 LBSC 690 Information Technology
Week 4 LBSC 690 Information TechnologyWeek 4 LBSC 690 Information Technology
Week 4 LBSC 690 Information Technology
 
Wireless PC2TV
Wireless PC2TVWireless PC2TV
Wireless PC2TV
 
PowerPoint 97
PowerPoint 97PowerPoint 97
PowerPoint 97
 
Slide
SlideSlide
Slide
 
Video Coding Standard
Video Coding StandardVideo Coding Standard
Video Coding Standard
 
2.Hardware.ppt
2.Hardware.ppt2.Hardware.ppt
2.Hardware.ppt
 
Commonly Used Image File Formats
Commonly Used Image File FormatsCommonly Used Image File Formats
Commonly Used Image File Formats
 
Preserving Audiovisual Materials (LIS 198-Digital Preservation)
Preserving Audiovisual Materials (LIS 198-Digital Preservation)Preserving Audiovisual Materials (LIS 198-Digital Preservation)
Preserving Audiovisual Materials (LIS 198-Digital Preservation)
 
Optimisation and Compression Intro
Optimisation and Compression IntroOptimisation and Compression Intro
Optimisation and Compression Intro
 
Battle of the Codecs
Battle of the CodecsBattle of the Codecs
Battle of the Codecs
 
Mm01 a vformat
Mm01 a vformatMm01 a vformat
Mm01 a vformat
 
MPEG4 codec for Access Grid
MPEG4 codec for Access GridMPEG4 codec for Access Grid
MPEG4 codec for Access Grid
 
MPEG4 codec for Access Grid
MPEG4 codec for Access GridMPEG4 codec for Access Grid
MPEG4 codec for Access Grid
 
85 videocompress
85 videocompress85 videocompress
85 videocompress
 
Introduction to computers
Introduction to computersIntroduction to computers
Introduction to computers
 
Hollerback's Guide to Digital Video on the Web
Hollerback's Guide to Digital Video on the WebHollerback's Guide to Digital Video on the Web
Hollerback's Guide to Digital Video on the Web
 
From paper to screen: Putting maps on the web
From paper to screen:  Putting maps on the webFrom paper to screen:  Putting maps on the web
From paper to screen: Putting maps on the web
 
Digital Image Processing and gis software systems
Digital Image Processing and gis software systemsDigital Image Processing and gis software systems
Digital Image Processing and gis software systems
 
Digital Watchdog DW-VFHD46T Data Sheet
Digital Watchdog DW-VFHD46T Data SheetDigital Watchdog DW-VFHD46T Data Sheet
Digital Watchdog DW-VFHD46T Data Sheet
 

Último

The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhisoniya singh
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...HostedbyConfluent
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesSinan KOZAK
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking MenDelhi Call girls
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 

Último (20)

The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | DelhiFULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
FULL ENJOY 🔝 8264348440 🔝 Call Girls in Diplomatic Enclave | Delhi
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
Transforming Data Streams with Kafka Connect: An Introduction to Single Messa...
 
Unblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen FramesUnblocking The Main Thread Solving ANRs and Frozen Frames
Unblocking The Main Thread Solving ANRs and Frozen Frames
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 

Compression2011

  • 1. compression from production format to distribution format erik.luyten@dml.kuleuven.be
  • 2. What's this ? René Margritte: La Trahison des Images (1928-29)
  • 4. Temporal resolution 2 images/second 5 images/second 12,5 images/second 25 images/second
  • 5. A very small image
  • 6. Spatial resolution 7 x 10 = 70 14 x 20 = 280 28 x 40 = 1120 56 x 80 = 4480 112 x 160 = 17920 224 x 320 = 71680 448 x 640 = 309120
  • 7. graylevel resolution 1 bit/ 2 2 bit/ 4 3 bit/ 8 4 bit/ 16 5 bit/ 32 6 bit/ 64 7 bit/128 8 bit/256
  • 8. Creating colour: mixing light RGB triangle Red channel Green channel Blue channel 3 x 8 bits 256 red steps 256 green steps 256 blue steps
  • 9. Color resolution 24 bit color pallet 8 bit color pallet 8 bit optimized pallet 4 bit color pallet 4 bit color pallet 244 KB file 28 KB file 28 KB file No “dithering” 16 KB file
  • 10. Video signal(uncompressed) 768 pixels Each pixel has 3 values: (3 bytes) 25 images/second • Red: 256 steps (1 byte) • Green: 256 steps (1 byte) • Blue: 256 steps (1 byte) Datarate for the RGB video signal: 768(pix) x 576(lines) x 3(byte) x 25(images)=32 MByte/sec(256 Mbit/sec)
  • 11. Video signal (component) 720 pixels Each pixel has 3 values: (2 bytes) • Luminace(Y): 256 steps (1 byte) 25 images/second • Cr (R-Y): 128 steps (1/2 byte) • Cb (B-Y): 128 steps (1/2 byte) Datarate for the component video signal: 720(pix) x 576(lines) x 2(byte) x 25(images)=20 MByte/sec(160 Mbit/sec)
  • 12. Audio signal Sampling Rate: 44,1 kHz (CD) Bit Depth: 16 bit (65.536 steps) Stereo: x 2 16 bit x 2 x 44.100 = 1.411.200 bps 1,4 Mbit/sec Production systems normally use a sampling rate of 48 kHz 16 bit x 2 x 48.000 = 1.536.000 bps
  • 13. Video distribution ?  1 second video: 32 Mbyte (256 Mbit/sec)  1 minute video: 1,9 GByte  1 hour video: 111 GByte Disk Network  floppy disk = 0,05 seconds  Ethernet 100 Mbit/sec (shared) LAN 1/2.5  CD-rom = 20 seconds  Ethernet 10 Mbit/sec (shared !) LAN 1/25  1 Gbyte hard disk = 32 seconds  ISDN lijn ( 2B + D) : 128Kbit/sec 1/2000  16 Gbyte array = 8 min 30 sec  Modem connection : 56 Kbit/sec 1/4600
  • 14. Compression techniques Lossless No information loss Lossy (Important) information is lost (f.i. medical applications) Intraframe (spatial compression) Compression within a single frame Interframe (temporal compression) Compression between successive frames Symmetric Coding and decoding equally processor intensive Asymmetric Coding is more processor intensive than decoding
  • 15. Lower datastream ? 320x240, 25fps, 24 bit 160x120 pix 43,2 Mbit/sec 10,4 Mbit/sec 12,5fps 8 bit 21,6 Mbit/sec 14,4 Mbit/sec
  • 16. Intraframe compression (in one frame) Run Length Encoding •without compression: one line of 100 (white) pixels 100 x 3 bytes = 300 bytes 100 • RLE compression pixels 100 identical white pixels in a row 2 bytes: total amount of pixels involved 3 bytes for the colour information 2 + 3 = 5 bytes of info for 100 pixels • Compression factor of 60:1 without information loss
  • 17. Other Intraframe techniques Discrete Cosine Transformation •JPEG, MPEG, DV,… •Type of Fourier Transformation •Blocks of 8 x 8 pixels and/or 16 x 16 Wavelet Compression •MPEG-4 (still image), JPEG2000 •Improving image resolution as more data are received Vector Quantization Fractal Compression
  • 18. Interframe compression Image 124 Image 125
  • 19. Interframe: MPEG (Moving Picture Expert Group) GOP Group Of Pictures I-pictures: (Intra pictures) reference image with complete information for one frame (scene changes, ...) P-pictures: (Predicted pictures) images are “predicted” using the information in earlier I or P pictures. B-pictures: (Bi-directional predicted) pictures are recomposed from information in earlier or later I or P pictures. B-pictures are never used as reference for other images. I B B P B B P B B P B B I Group Of Pictures (GOP)
  • 20. Movie Formats File Format: Specifies how data are arranged in a file (interleaving video and audio) Codec: Specifies how (image) data is compressed Architecture: Synchronisation of different media components (video, audio, language tracks, text,…. tracks) Control for interactivity, alternate tracks,…
  • 21. Movie Architectures  QuickTime  AVI  Windows Media Player  Real Media  Flash ?  MPEG-4
  • 22. Media platform platform distribution cost alternates remarks RTSP alternates QTVR, text, midi, SMIL,.. Player = free production and Mac CD rom HTTP alternates QuickTim Windows Download (HTTP) Pro = €30 distribution Mixed alternates e (Linux) Streaming (RTSP) Server= open Skip prot.,instant - H.264 srce on Player = free RTSP alternates Windows Streaming (RTSP) Superpass=$13/ (Surestream only distribution and Real Mac Download (HTTP) m techn.) mainly for streaming Linux Server=payable Dynamic Windows Streaming ( ) Player=free Production anddistribution Windows (Mac) Download (HTTP) RTSP alternates Server= Version 9 on windows Media Dynamic (Linux) CD rom Windows2003 platform Flash Windows CD rom (Spark, Player=free Mac Download (HTTP) Server=€4759 ? H.264 On2, Linux Streaming h264) Player=QT, Industrie standaard Streaming (RTSP) Windows Real,… Download (HTTP) scalable (in the from handheld to HD MPEG-4 Mac CD rom Server=open future) srce Linux DVD, GSM, …. H.264
  • 23. File Formats  DV  MPEG-1  MPEG-2  MPEG-4
  • 24. Codec’s  Picture: • Cinepak • Indeo (Intel Indeo) • H.261, H.263, H.264 • Sorenson • M-JPEG • MPEG-1, MPEG-2, MPEG-4 • DV  Sound: • IMA • Qualcomm PureVoice, Qdesign Music,… • MP3 • AAC (Advanced Audio Coding) • WMA, RealAudio
  • 25. MPEG-1, MPEG-2 MPEG-4 difference MPEG-4 vs MPEG-1/2 display and video scaling Decompression compression Composition subtitles Rendering display and transport and background scaling graphics MPEG-4 display Scaling, Rendering Decompression video Bitmap stream transport Composition Compression subtitles ASCI code transport display and background Bitmap image transport graphics Vector code transport
  • 26. Codec’s and bitrate Web ? Distribution codec’s Production codec’s 56 kbit 200 kbit 1 Mbit 9 Mbit 25 Mbit 256 Mbit uncompr. MPEG-1 MPEG-2 H-261 H-263 Sorenson DV profile 0 profile 1 MPEG-4 MPEG-4 H.264 PIM, GSM, ... HD distribution Studio production
  • 27. Comparing codecs Cinepack : 4,2 Mbit/sec H-263 : 2 Mbit/sec MPEG 1: 1,8 Mbit/sec Sorenson : 1,35 Mbit/sec MPEG-4 : 960 Kbit/sec H.264 : 502 Kbit/sec
  • 28. Video to Computer • Video recording • Interlaced, 25 frames - 50 fields per second • Restricted to 576 effective lines (PAL) and 3x4 picture aspect ratio. • Computer image • Non-interlaced, 60 to 80 frames per second • No restrictions on picture format and aspect ratio • De-interlacing of video material is desirable.
  • 29. De-interlacing Field 1 313 Field 2 1 314 2 315 3 623 311 624 312 625 313
  • 30. Delivery methods  DVD, CD, USB stick,…  Internet • Progressive download (HTTP, FTP)  “file transport” type (TCP protocol)  No data loss: resent lost packages  No real-time events  Complete file must be downloaded to allow random access.  No special server needed (normal web service over http) • Streaming media (RTP)  RTSP transport (UDP protocol)  Lost data (probably) will not be recovered  Real-time events possible  “Random access” possibility (only needed fragments will be downloaded)  Needs one or more(worldwide proxy delivery) streaming servers
  • 31. (Progressive) download Web server http:// http:// www.avnet.kuleuven.be/ www.avnet.kuleuven.be/ staalkaart/2004/video04.mov staalkaart/2004/video04.html <object classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" codebase="http://www.apple.com/qtactivex/qtplugin.cab" width="320" height="195"> <param name="loop" value="false"> File : video04.mov <param name="cache" value="true"> <param name="src" value="video04.mov"> TCP/IP <param name="autoplay" value="true"> <param name="controller" value="true"> <embed width="320" height="195" pluginspage="http://www.apple.com/quicktime/download/" src="video04.mov" type="video/quicktime" controller="true" autoplay="true" cache="true" loop="false"> </object>
  • 32. (video) podcasting  Audio or audio/video distribution via internet  Download file to client computer  Mostly used for handheld devices  Broadcast channel ---> Feeds  Programs ---> Episodes
  • 33. Podcast delivery: URL link Web server AVNet •Request for web pqge •HTML with itpc link •Request XML data •XML file + startup iTunes •Request for episodes •HTTP download episodes to iTunes Client computer
  • 34. RTSP streaming (or RTMP) Web server Streaming server http:// Datastream www.avnet.kuleuven.be/ RTP over UDP Videotechniek/medatech.html <object classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" width="384" height="304" codebase="http://www.apple.com/qtactivex/qtplugin.cab"> <param name="autoplay" value="true"> <param name="controller" value="true"> <param name="pluginspage" value="http://www.apple.com/quicktime/download/indext.html"> <param name="target" value="myself"> <param name="type" value="video/quicktime"> <param name="src" value="jaarverslag0304_384k.mov"> rtsp://escher.avnet.kuleuven.be/ <param name="HREF" value="rtsp://escher.avnet.kuleuven.be/mediatechnologie/mediatech_384k.mov"> <embed src="comtechn.mov" width="384" height="304" autoplay="true" mediatechnologie/mediatech_384k.mov controller="true" border="0" pluginspage="http://www.apple.com/quicktime/download/indext.html" target="myself" type="video/quicktime" href="rtsp://escher.avnet.kuleuven.be/mediatechnologie/mediatech_384k.mov"></embed> </object>
  • 37. HTTP streaming (iPhone, iPad,…)  Ordinary webserver (Apache 2.2) • Apple HLS  Segmented distribution of material. • Microsoft Smooth Streaming  Material is chopped in 10 sec files • Adobe Flash HTTP Dynamic  Index file with info on different segments Streaming  Distributed to client using http protocol  VOD via h.264 compressed material  Live streaming possible  Latency 20-30 sec  Stream segmenter #EXTM3U #EXT-X-MEDIA-SEQUENCE:0 #EXT-X-TARGETDURATION:10 #EXTINF:10, http://media.example.com/segment1.ts #EXTINF:10, http://media.example.com/segment2.ts #EXTINF:10, http://media.example.com/segment3.ts #EXT-X-ENDLIST