1 / 19

Digital Formats & Compression

Digital Formats & Compression. How Analog and Digital Recording Works. Analog converted to digital via an ADV ( Analog to D igital C onverter = stream of numbers) On playback: digital converted to analog wave via a DAC (Digital to A nalog Converter)

erica
Download Presentation

Digital Formats & Compression

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Digital Formats & Compression

  2. How Analog and Digital Recording Works • Analogconverted to digital via an ADV (Analogto Digital Converter = stream of numbers) • On playback: digital converted to analog wave via a DAC (Digital to Analog Converter) • Digital never changes (unless corruption occurs)

  3. How Analog and Digital Recording Works • What are the two variables that affect the quality?                 1) Sampling rate - samples per second                                Higher sample rate = higher fidelity                                Usually 44,100 SPS for CD                2) Sampling precision - sample accuracy                                Higher precision = higher fidelity                                Usually 65,536                    Sampling error = detail missed in conversion

  4. Sampling precision • What's so special about 65,536

  5. Sampling precision • What's so special about 65,536 • On a CD each sample is recorded as a binary number up between 1 and 65,536 • This number is written in binary code in two bytes (16 bits) / bit = binary digit • What's this number? • 00000111 • 01000000

  6. Sampling precision • 0 = 0000000000000000 • 65535 = 1111111111111111 0 =          04 =      1008 =    100012 =    110016 = 1000020 = 10100

  7. How File Compression Works • What's the point of compression? (why do we need it?)

  8. How File Compression Works • Reduce redundancies (number of bits and bytes in file) • In John F. Kennedy's 1961 inaugural address, he delivered this famous line: "Ask not what your  country can do for you -- ask what you can do for your country.“ • 17 words - 61 letters, 16 spaces, one dash and one period. If each letter, space or punctuation mark takes up one unit of memory, we get a total file size of 79 units."ask" appears two times"what" appears two times"your" appears two times"country" appears two times"can" appears two times"do" appears two times "for" appears two times"you" appears two times • Ignoring the difference between capital and lower-case letters, roughly half of the phrase is redundant.

  9. How File Compression Works • Reducing redundancy is about finding patterns (LZ adaptive dictionary-based algorithm) • ask • what • your • country • can • do • for • you • 1 not 2 3 4 5 6 7 8 -- 1 2 8 5 6 7 3 4 (74 units)

  10. How File Compression Works • Reducing redundancy is about finding patterns (LZ adaptive dictionary-based algorithm) • ask__ • what__ • you • r__country • __can__do__for__you • 1not__2345__--__12354 (59 units)

  11. Lossless vsLossyCompression • Do you know the difference?

  12. Lossless vsLossyCompression • Do you know the difference? • Lossless = exact file • Lossy= not exact file.  (Original file cannot be reproduced / not for programs, etc).

  13. Audio File Formats   • What file formats do you know? • Why do you think we have so many different audio, image and video formats?

  14. Audio File Formats   • Audio file is defined by two factors: • File type -  most common are Wave files (wav) and MPEG Layer-3 files (mp3) Container - packaged, transported, and presented • Codec - way the audio is compressed and stored (different file types may use the same codec)Compressor - decompressor • Open file formats - playable on most devices                          E.g., wav, mp3 • Proprietary formats - may include DRM (Digital Rights Management) or other copy protection                          E.g., wma, aac • Compression (eliminating parts that are inaudible)

  15. Image File Formats • What file formats do you know?

  16. Image File Formats • Different file types (compress image in different ways) Main - Tiff, Jpeg                Binary (on off / 0 1)                                1 bit colour (2 / white or black)                                2 bit (4)                                3 bit (8)                                8 bit (256) • TIFF- lossless (usually) or lossy / usually large file size (little or no compression / LZW). • JPEG- discards information eye will not notice (24 bit color / good compression)                   High quality digital photographs. • PNG- lossless (exactly reversible / looks for patterns) • GIF- Selects 256 colour pallet (16 million, lossless < 256 lossy > 256) / More than 256 (blends) • RAW - lossless, smaller than TIFF /  varies by manufacturer (camera). • BMP- uncompressed, proprietary (MS) / do not use • PSD, PSP - proprietary  (layers) / may be obsolete when software updates. Use for editing

  17. Video File Formats • What file formats do you know?

  18. Video File Formats • Some video formats are more compatible than others (codec = compression) • Popular containers (Quicktime MOV, Windows AVI, Flash FLV, MPEG4 MP4, Windows WMV) • Packages - video stream, audio stream, metadata, subtitles and chapter-informationWMV, AVI, Quicktime - higher quality, higher file sizes.                      WMV - Windows only, Mac with player                      AVI - Windows only, Mac with playerQuicktime- both MPEG - (MPEG 1 - video CD's, MPEG 2 - broadcast / DVD, MPEG 4 -                                Digital Rights Management / copying)        H.264 - codec for HD/Blu-Ray                           YouTube - H.264/MPEG-4 AVC format, with stereo AAC audio                           High quality, low bit rates = smaller fileDivX - different codec /  Still high quality, small file, lossy

  19. Exporting for use on the Web • Find balance (quality v file size) • Video (mobile - 464 kbps, DVD - 8000kbps) • Export to .swf for animations, regardless of the program you're using!

More Related