Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Digital Image and Video Compression - Prof. Geen, Lecture notes of Web Design and Development

An in-depth analysis of digital image and video compression, covering topics such as frame rate, color quantization, pixel density, bit rate, container file formats, and audio compression. It explains various techniques to reduce file size, improve playback quality, and optimize storage requirements for videos.

Typology: Lecture notes

2022/2023

Uploaded on 04/11/2024

lisa-yu-1
lisa-yu-1 🇨🇦

6 documents

1 / 5

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Video:
What is each still image called? Frame
Humans can distinguish as single images at less than 10 fps (frames per second)
each pixel gets assigned a color: 2 colors - 1 bit color; 16 million colors - 24 bit color (quantization
process)
human notices change of brightness more easily than changes of color
TV:
I: interlaced (every other line of a image is displayed in one frame); only for older TVs (480 horizontal
scan lines, i.e. 480i)
P: progressive (draw all of the lines in a single framed video sequantially); e.g.: 720P: 720 horizontal scan
lines
Notice: 4K and 8K are vertical scan lines (almost 4000 and 8000 vertical lines of pixels / numbers of
pixels)
480P resolution TV is 720*480 & Total pixels = 345,600
720P resolution TV is 1280*720 & Total pixels = 921,600
100P resolution TV is 1920*1080 & Total pixels = 2,073,600
4K resolution TV is 3840*2160 & Total pixels = 8,294,400
8K resolution TV is 7680*4320 & Total pixels = 33,177,600
Retina Display:
Pixel density (300)
Viewing distance
Display size
pf3
pf4
pf5

Partial preview of the text

Download Digital Image and Video Compression - Prof. Geen and more Lecture notes Web Design and Development in PDF only on Docsity!

Video: What is each still image called? Frame Humans can distinguish as single images at less than 10 fps (frames per second) each pixel gets assigned a color: 2 colors - 1 bit color; 16 million colors - 24 bit color (quantization process) human notices change of brightness more easily than changes of color TV: I: interlaced (every other line of a image is displayed in one frame); only for older TVs (480 horizontal scan lines, i.e. 480i) P: progressive (draw all of the lines in a single framed video sequantially); e.g.: 720P: 720 horizontal scan lines Notice: 4K and 8K are vertical scan lines (almost 4000 and 8000 vertical lines of pixels / numbers of pixels) 480P resolution TV is 720480 & Total pixels = 345, 720P resolution TV is 1280720 & Total pixels = 921, 100P resolution TV is 19201080 & Total pixels = 2,073, 4K resolution TV is 38402160 & Total pixels = 8,294, 8K resolution TV is 7680*4320 & Total pixels = 33,177, Retina Display: Pixel density (300) Viewing distance Display size

Compute the size of video: Assume we have video that is: 1440 X 1080 pixels = 1,555,200 pixels per frame 24 - bit colour 30 fps 1 second long Audio is stereo so 2 channels Audio is 48,000Hz and 16 bit = 48,0001sec * 16bits/sample * 2=1,536,000bits Video: 1,555,200 X 24 bits per pixel (for color) = 37,324,800 bits per frame 37,324,800 * 30 frames per second * 1 second= 1,119,744,000 bits / 8 = 139,968,000 bytes = 133MB Audio: 1,536,000bits/8 = 188 KB Total: 133MB + 188KB =~ 133MB --> LOTS OF STORAGE FOR JUST 1 SECOND, OR 1,067Mb(1338) OR 1.04Gb(1067/1024) THUS a DVD could hold 35 seconds of uncompressed video… Not a very long movie Bit rate / data rate / playback rate: amount of video processed per second (amount of data used to encode video or audio) Average bit rate = file size / full length(second) Normally measured in bits (b in lowercase) not bytes (b in uppercase)

Unicast: each user gets his/her own stream of video, the server has to send out A LOT of data if several users are watching at once Multicast: send the same stream to a bunch of users but then they lose the ability to pause, rewind, etc. If you encode at the same bit rate and the bitrate is low, the 1080p video will be clearer than the 4K video because it had less compression done to it. Sound: Pitch or frequency - the closer together the waves the higher the pitch The Nyquist Limit: you MUST take at least 2 samples for every cycle of the wave, otherwise you will get a completely different sound wave. So, it means you have to take more samples for higher pitched sounds than lower pitched sounds. Number of samples per second is represented in Hertz (Hz) For CD quality we need 44,100 samples per second or 44,100Hz or 44.1KHz typical sample rate: Voice Only (Telephone Quality) 8 KHz AM Radio Quality 11.025 KHz FM Radio Quality 22 KHz CD Quality Music 44.1KHz x bit sampling means 2^x tones per sample (as picture:x bit color = 2^x colors for each pixel) CDs use 16-bit rate (2^16 = 65,536 possible values could be given to each sample) higher bit rate for the sample size: advantage - good quality; disadvantage - huge file size

An example of uncompressed sound with CD quality for 1 minute of audio: 1 minute of recording 60 seconds 60 * 44,100 samples/second 2,646,000 samples 2,646,000 samples * 16bits per sample 42,336,000 bits 42,336,000 bits * 2 (stereo, 2 channels) 84,672,000 bits 84,672,000 bits / (8bits per byte) 10,884,100 About 10 MB (Megabytes)!!! A typical CD can hold about 737MB (or 80 minutes of audio) Three ways to compress audio: reduce the sample rate (go from 44KHz to 22KHz) reduce the sample size (go from 16 bit to 8 bit) reduce the number of channels (changing from stereo (two channels) to mono (one channel)) .mp3: good compression .wav: good sound quality MIDI file: deals with music and synthesized sound, but does not handle voice (like someone singing a song) or noise well offer a staffview, i.e sheetmusic advantage: very very small disadvantage: not all browsers play them easily, may need a plug-in to convert it to a .wav or .mp3 type file video only: only needs 8000HZ or 8KHz, so you can reduce the number of samples which will greatly increase your compression