Documente Academic
Documente Profesional
Documente Cultură
CODEC WORKS
I'm not a runway but I don't have
either twitter or FB
MISSION: IMPOSSIBLE
OUR GOAL
1 bit
2 bits
1B = 8 bits
#qacodec
width
height
4 x 4 x 1 = 16B
#qacodec
LET'S COLORIZE IT
(RGB PRIMARY COLORS)
X
#qacodec
https://lumeniquessl.com/2012/03/01/12-in-12-for-2012-the-flicker-indicator-machine/
https://lightingstudio.wordpress.com/2012/03/27/week5-light-object-shadow-contrast/
#qacodec
width
height
color
#qacodec
4 x 4 x 3 = 48B
BEFORE WE MOVE ON...
#qacodec
#qacodec
MATRIX OF NUMBERS
15 0 0 0
15 15 15 15
0
20 10 0 0
20 10 10 10
0
16 13 13 13
25 14 14 14
#qacodec
time
4 x 4 x 3 x 30 = 1440B
A SINGLE TV SHOW
EPISODE
#qacodec
The eye contains about 120M rod cells and 6M cone cells.
#qacodec
AN ALTERNATIVE TO RGB
#qacodec
*ITU-R BT.601-7
#qacodec
CHROMA SUBSAMPLING
1280 320
180
720
#qacodec
24 bits per
pixel
12 bits per
pixel
#qacodec
CORRELATIONS IN TIME
#qacodec
TEMPORAL REDUNDANCY
ORIGINAL FRAMES
FRAME DIFFERENCE
#qacodec
diff + reference
frame 0 frame 1
CAN WE DO BETTER?
#qacodec
frame 1 frame 2
#qacodec
TEMPORAL REDUNDANCY
(INTER PREDICTION)
FRAMES THAT CAN'T BE
EASILY EXPLOITED BY
TEMPORAL REDUNDANCY
#qacodec
CORRELATIONS IN SPACE
LOTS OF
SIMILARITIES
PATTERNS /
DIRECTIONS
SPATIAL REDUNDANCY
(INTRA PREDICTION)
100 100 100 200 100 100 100 200 100 100 100 200 100 100 100 200
100 ??? ??? ??? 100 100 100 200 100 100 100 200 100 0 0 0
100 ??? ??? ??? 100 100 100 200 100 100 100 200 100 0 0 0
100 ??? ??? ??? 100 100 100 200 100 100 120 210 100 0 20 10
* Pied Piper is a startup company focused on "multi-platform technology based on a proprietary universal compression algorithm" featured in the HBO series Silicon Valley
CODEC
Compressed
Video Source Display
Video
Compress Decompress
(enCOde) (DECode)
Compressed
Video Source Display
Video
Compress Decompress
(enCOde) (DECode)
picture entropy
predictions transform quantization
partitioning coding
entropy lossless
technique redundancy removal
reduction compression
picture entropy
predictions transform quantization
partitioning coding
entropy lossless
technique redundancy removal
reduction compression
picture entropy
predictions transform quantization
partitioning coding
entropy lossless
technique redundancy removal
reduction compression
picture entropy
predictions transform quantization
partitioning coding
entropy lossless
technique redundancy removal
reduction compression
picture entropy
predictions transform quantization
partitioning coding
entropy lossless
technique redundancy removal
reduction compression
https://www.mathworks.com/help/images/discrete-cosine-transform.html
ENCODER
picture entropy
predictions transform quantization
partitioning coding
entropy lossless
technique redundancy removal
reduction compression
27 10 0 0
10 0 0 0
0 0 0 0
0 0 0 0
ZIG-ZAG SCAN
(FROM 2D TO 1D)
27 10 0 0
10 0 0 0
27,10,10,0,0,0,0,0,0,0,0,0,0,0,0,0
0 0 0 0
0 0 0 0
PROBABILITY OF EACH SYMBOL
symbols 27 10 0
27,10,10,0,0,0,0,0,0,0,0,0,0,0,0,0
probability 1/16 2/16 13/16
BITCODE
symbols 27 10 0
27,10,10,0,0,0,0,0,0,0,0,0,0,0,0,0 16B
*CAVLC example
FROM MANY BYTES TO FEW BITS
0001101100001010000010100000
0000000000000000000000000000
0000000000000000000000000000 010101101101 + code table
0000000000000000000000000000
0000000000000000
ENCODER
picture entropy
predictions transform quantization
partitioning coding
entropy lossless
technique redundancy removal
reduction compression
picture predictions
transform quantization entropy coding
partitioning (subtract)
DECODER
bit.ly/intro_codec
LEANDRO MOREIRA
leandromoreira.com.br
Disclaimer: The views and opinions expressed in this presentation are those of the authors and do not
necessarily reflect the policy or position of Globo.