<s>
A	O
video	B-Application
codec	I-Application
is	O
software	O
or	O
hardware	B-Architecture
that	O
compresses	B-General_Concept
and	O
decompresses	B-Device
digital	O
video	O
.	O
</s>
<s>
In	O
the	O
context	O
of	O
video	O
compression	O
,	O
codec	B-General_Concept
is	O
a	O
portmanteau	O
of	O
encoder	O
and	O
decoder	O
,	O
while	O
a	O
device	O
that	O
only	O
compresses	B-General_Concept
is	O
typically	O
called	O
an	O
encoder	O
,	O
and	O
one	O
that	O
only	O
decompresses	B-Device
is	O
a	O
decoder	O
.	O
</s>
<s>
The	O
compressed	B-General_Concept
data	I-General_Concept
format	O
usually	O
conforms	O
to	O
a	O
standard	O
video	B-Algorithm
coding	I-Algorithm
format	I-Algorithm
.	O
</s>
<s>
The	O
compression	O
is	O
typically	O
lossy	B-Algorithm
,	O
meaning	O
that	O
the	O
compressed	O
video	O
lacks	O
some	O
information	O
present	O
in	O
the	O
original	O
video	O
.	O
</s>
<s>
A	O
consequence	O
of	O
this	O
is	O
that	O
decompressed	O
video	O
has	O
lower	O
quality	O
than	O
the	O
original	O
,	O
uncompressed	B-Device
video	I-Device
because	O
there	O
is	O
insufficient	O
information	O
to	O
accurately	O
reconstruct	O
the	O
original	O
video	O
.	O
</s>
<s>
There	O
are	O
complex	O
relationships	O
between	O
the	O
video	B-Device
quality	I-Device
,	O
the	O
amount	O
of	O
data	O
used	O
to	O
represent	O
the	O
video	O
(	O
determined	O
by	O
the	O
bit	O
rate	O
)	O
,	O
the	O
complexity	O
of	O
the	O
encoding	O
and	O
decoding	O
algorithms	O
,	O
sensitivity	O
to	O
data	O
losses	O
and	O
errors	O
,	O
ease	O
of	O
editing	O
,	O
random	O
access	O
,	O
and	O
end-to-end	O
delay	O
(	O
latency	O
)	O
.	O
</s>
<s>
Because	O
of	O
the	O
large	O
amount	O
of	O
storage	O
and	O
bandwidth	O
needed	O
to	O
record	O
and	O
convey	O
raw	B-Device
video	I-Device
,	O
a	O
method	O
was	O
needed	O
to	O
reduce	O
the	O
amount	O
of	O
data	O
used	O
to	O
represent	O
the	O
raw	B-Device
video	I-Device
.	O
</s>
<s>
In	O
1974	O
,	O
discrete	B-General_Concept
cosine	I-General_Concept
transform	I-General_Concept
(	O
DCT	B-General_Concept
)	O
compression	O
was	O
introduced	O
by	O
Nasir	O
Ahmed	O
,	O
T	O
.	O
Natarajan	O
and	O
K	O
.	O
R	O
.	O
Rao	O
.	O
</s>
<s>
During	O
the	O
late	O
1980s	O
,	O
a	O
number	O
of	O
companies	O
began	O
experimenting	O
with	O
DCT	B-General_Concept
lossy	B-Algorithm
compression	I-Algorithm
for	O
video	B-Algorithm
coding	I-Algorithm
,	O
leading	O
to	O
the	O
development	O
of	O
the	O
H.261	B-Algorithm
standard	I-Algorithm
.	O
</s>
<s>
H.261	B-Algorithm
was	O
the	O
first	O
practical	O
video	B-Algorithm
coding	I-Algorithm
standard	I-Algorithm
,	O
and	O
was	O
developed	O
by	O
a	O
number	O
of	O
companies	O
,	O
including	O
Hitachi	O
,	O
PictureTel	B-Application
,	O
NTT	O
,	O
BT	O
,	O
and	O
Toshiba	O
,	O
among	O
others	O
.	O
</s>
<s>
Since	O
H.261	B-Algorithm
,	O
DCT	B-General_Concept
compression	O
has	O
been	O
adopted	O
by	O
all	O
the	O
major	O
video	B-Algorithm
coding	I-Algorithm
standards	I-Algorithm
that	O
followed	O
.	O
</s>
<s>
The	O
most	O
popular	O
video	B-Algorithm
coding	I-Algorithm
standards	I-Algorithm
used	O
for	O
codecs	B-General_Concept
have	O
been	O
the	O
MPEG	O
standards	O
.	O
</s>
<s>
MPEG-1	B-Algorithm
was	O
developed	O
by	O
the	O
Motion	O
Picture	O
Experts	O
Group	O
(	O
MPEG	O
)	O
in	O
1991	O
,	O
and	O
it	O
was	O
designed	O
to	O
compress	O
VHS-quality	O
video	O
.	O
</s>
<s>
It	O
was	O
succeeded	O
in	O
1994	O
by	O
MPEG-2/H.262	O
,	O
which	O
was	O
developed	O
by	O
a	O
number	O
of	O
companies	O
,	O
primarily	O
Sony	O
,	O
Thomson	O
and	O
Mitsubishi	O
Electric	O
.	O
</s>
<s>
MPEG-2	B-Algorithm
became	O
the	O
standard	O
video	O
format	O
for	O
DVD	O
and	O
SD	B-Device
digital	I-Device
television	I-Device
.	O
</s>
<s>
In	O
1999	O
,	O
it	O
was	O
followed	O
by	O
MPEG-4/H.263	O
,	O
which	O
was	O
a	O
major	O
leap	O
forward	O
for	O
video	O
compression	O
technology	O
.	O
</s>
<s>
The	O
most	O
widely	O
used	O
video	B-Algorithm
coding	I-Algorithm
format	I-Algorithm
,	O
as	O
of	O
2016	O
,	O
is	O
H.264/MPEG	B-Application
-4	I-Application
AVC	I-Application
.	O
</s>
<s>
H.264	B-Application
is	O
the	O
main	O
video	O
encoding	O
standard	O
for	O
Blu-ray	O
Discs	O
,	O
and	O
is	O
widely	O
used	O
by	O
streaming	O
internet	O
services	O
such	O
as	O
YouTube	B-General_Concept
,	O
Netflix	O
,	O
Vimeo	O
,	O
and	O
iTunes	O
Store	O
,	O
web	O
software	O
such	O
as	O
Adobe	B-Operating_System
Flash	I-Operating_System
Player	I-Operating_System
and	O
Microsoft	B-Application
Silverlight	I-Application
,	O
and	O
various	O
HDTV	B-Device
broadcasts	O
over	O
terrestrial	O
and	O
satellite	O
television	O
.	O
</s>
<s>
AVC	O
has	O
been	O
succeeded	O
by	O
HEVC	B-Algorithm
(	O
H.265	B-Algorithm
)	O
,	O
developed	O
in	O
2013	O
.	O
</s>
<s>
The	O
adoption	O
of	O
HEVC	B-Algorithm
has	O
been	O
hampered	O
by	O
its	O
complex	O
licensing	O
structure	O
.	O
</s>
<s>
HEVC	B-Algorithm
is	O
in	O
turn	O
succeeded	O
by	O
Versatile	B-Algorithm
Video	I-Algorithm
Coding	I-Algorithm
(	O
VVC	O
)	O
.	O
</s>
<s>
There	O
are	O
also	O
the	O
open	O
and	O
free	O
VP8	B-Algorithm
,	O
VP9	B-Algorithm
and	O
AV1	B-Application
video	B-Algorithm
coding	I-Algorithm
formats	I-Algorithm
,	O
used	O
by	O
YouTube	B-General_Concept
,	O
all	O
of	O
which	O
were	O
developed	O
with	O
involvement	O
from	O
Google	B-Application
.	I-Application
</s>
<s>
Video	B-Application
codecs	I-Application
are	O
used	O
in	O
DVD	O
players	O
,	O
Internet	O
video	O
,	O
video	B-Application
on	I-Application
demand	I-Application
,	O
digital	B-Device
cable	I-Device
,	O
digital	B-Application
terrestrial	I-Application
television	I-Application
,	O
videotelephony	B-Application
and	O
a	O
variety	O
of	O
other	O
applications	O
.	O
</s>
<s>
In	O
particular	O
,	O
they	O
are	O
widely	O
used	O
in	O
applications	O
that	O
record	O
or	O
transmit	O
video	O
,	O
which	O
may	O
not	O
be	O
feasible	O
with	O
the	O
high	O
data	O
volumes	O
and	O
bandwidths	O
of	O
uncompressed	B-Device
video	I-Device
.	O
</s>
<s>
For	O
example	O
,	O
they	O
are	O
used	O
in	O
operating	O
theaters	O
to	O
record	O
surgical	O
operations	O
,	O
in	O
IP	B-Algorithm
cameras	I-Algorithm
in	O
security	O
systems	O
,	O
and	O
in	O
remotely	O
operated	O
underwater	O
vehicles	O
and	O
unmanned	O
aerial	O
vehicles	O
.	O
</s>
<s>
Any	O
video	B-Application
stream	I-Application
or	O
file	O
can	O
be	O
encoded	O
using	O
a	O
wide	O
variety	O
of	O
live	O
video	O
format	O
options	O
.	O
</s>
<s>
Here	O
are	O
some	O
of	O
the	O
H.264	B-Application
encoder	O
settings	O
that	O
need	O
to	O
be	O
set	O
when	O
streaming	O
to	O
an	O
HTML5	O
video	O
player	O
.	O
</s>
<s>
Video	B-Application
codecs	I-Application
seek	O
to	O
represent	O
a	O
fundamentally	O
analog	O
data	O
set	O
in	O
a	O
digital	O
format	O
.	O
</s>
<s>
Because	O
of	O
the	O
design	O
of	O
analog	O
video	O
signals	O
,	O
which	O
represent	O
luminance	O
(	O
luma	O
)	O
and	O
color	O
information	O
(	O
chrominance	O
,	O
chroma	O
)	O
separately	O
,	O
a	O
common	O
first	O
step	O
in	O
image	O
compression	O
in	O
codec	B-General_Concept
design	O
is	O
to	O
represent	O
and	O
store	O
the	O
image	O
in	O
a	O
YCbCr	O
color	O
space	O
.	O
</s>
<s>
The	O
conversion	O
to	O
YCbCr	O
provides	O
two	O
benefits	O
:	O
first	O
,	O
it	O
improves	O
compressibility	O
by	O
providing	O
decorrelation	O
of	O
the	O
color	O
signals	O
;	O
and	O
second	O
,	O
it	O
separates	O
the	O
luma	O
signal	O
,	O
which	O
is	O
perceptually	O
much	O
more	O
important	O
,	O
from	O
the	O
chroma	O
signal	O
,	O
which	O
is	O
less	O
perceptually	O
important	O
and	O
which	O
can	O
be	O
represented	O
at	O
lower	O
resolution	O
using	O
chroma	O
subsampling	O
to	O
achieve	O
more	O
efficient	O
data	B-General_Concept
compression	I-General_Concept
.	O
</s>
<s>
Different	O
codecs	B-General_Concept
use	O
different	O
chroma	O
subsampling	O
ratios	O
as	O
appropriate	O
to	O
their	O
compression	O
needs	O
.	O
</s>
<s>
Professional	O
video	B-Application
codecs	I-Application
designed	O
to	O
function	O
at	O
much	O
higher	O
bitrates	O
and	O
to	O
record	O
a	O
greater	O
amount	O
of	O
color	O
information	O
for	O
post-production	O
manipulation	O
sample	O
in	O
4:2:2	O
and	O
4:4:4	O
ratios	O
.	O
</s>
<s>
Examples	O
of	O
these	O
codecs	B-General_Concept
include	O
Panasonic	O
's	O
DVCPRO50	O
and	O
DVCPROHD	O
codecs	B-General_Concept
(	O
4:2:2	O
)	O
,	O
Sony	O
's	O
HDCAM-SR	O
(	O
4:4:4	O
)	O
,	O
Panasonic	O
's	O
HDD5	O
(	O
4:2:2	O
)	O
,	O
Apple	O
's	O
Prores	O
HQ	O
422	O
(	O
4:2:2	O
)	O
.	O
</s>
<s>
It	O
is	O
also	O
worth	O
noting	O
that	O
video	B-Application
codecs	I-Application
can	O
operate	O
in	O
RGB	O
space	O
as	O
well	O
.	O
</s>
<s>
These	O
codecs	B-General_Concept
tend	O
not	O
to	O
sample	O
the	O
red	O
,	O
green	O
,	O
and	O
blue	O
channels	O
in	O
different	O
ratios	O
,	O
since	O
there	O
is	O
less	O
perceptual	O
motivation	O
for	O
doing	O
so	O
—	O
just	O
the	O
blue	O
channel	O
could	O
be	O
undersampled	O
.	O
</s>
<s>
Some	O
amount	O
of	O
spatial	O
and	O
temporal	O
downsampling	B-Algorithm
may	O
also	O
be	O
used	O
to	O
reduce	O
the	O
raw	B-Application
data	O
rate	O
before	O
the	O
basic	O
encoding	O
process	O
.	O
</s>
<s>
The	O
most	O
popular	O
encoding	O
transform	O
is	O
the	O
8x8	O
DCT	B-General_Concept
.	O
</s>
<s>
Codecs	B-General_Concept
which	O
make	O
use	O
of	O
a	O
wavelet	O
transform	O
are	O
also	O
entering	O
the	O
market	O
,	O
especially	O
in	O
camera	O
workflows	O
which	O
involve	O
dealing	O
with	O
RAW	B-Application
image	I-Application
formatting	O
in	O
motion	O
sequences	O
.	O
</s>
<s>
This	O
process	O
involves	O
representing	O
the	O
video	O
image	O
as	O
a	O
set	O
of	O
macroblocks	B-General_Concept
.	O
</s>
<s>
For	O
more	O
information	O
about	O
this	O
critical	O
facet	O
of	O
video	B-Application
codec	I-Application
design	O
,	O
see	O
B-frames	B-General_Concept
.	O
</s>
<s>
The	O
output	O
of	O
the	O
transform	O
is	O
first	O
quantized	B-Algorithm
,	O
then	O
entropy	B-Algorithm
encoding	I-Algorithm
is	O
applied	O
to	O
the	O
quantized	B-Algorithm
values	O
.	O
</s>
<s>
When	O
a	O
DCT	B-General_Concept
has	O
been	O
used	O
,	O
the	O
coefficients	O
are	O
typically	O
scanned	O
using	O
a	O
zig-zag	O
scan	O
order	O
,	O
and	O
the	O
entropy	B-Algorithm
coding	I-Algorithm
typically	O
combines	O
a	O
number	O
of	O
consecutive	O
zero-valued	O
quantized	B-Algorithm
coefficients	O
with	O
the	O
value	O
of	O
the	O
next	O
non-zero	O
quantized	B-Algorithm
coefficient	O
into	O
a	O
single	O
symbol	O
,	O
and	O
also	O
has	O
special	O
ways	O
of	O
indicating	O
when	O
all	O
of	O
the	O
remaining	O
quantized	B-Algorithm
coefficient	O
values	O
are	O
equal	O
to	O
zero	O
.	O
</s>
<s>
The	O
entropy	B-Algorithm
coding	I-Algorithm
method	O
typically	O
uses	O
variable-length	B-Algorithm
coding	I-Algorithm
tables	I-Algorithm
.	O
</s>
<s>
The	O
one	O
stage	O
that	O
cannot	O
be	O
exactly	O
inverted	O
is	O
the	O
quantization	B-Algorithm
stage	O
.	O
</s>
<s>
This	O
part	O
of	O
the	O
process	O
is	O
often	O
called	O
inverse	O
quantization	B-Algorithm
or	O
dequantization	O
,	O
although	O
quantization	B-Algorithm
is	O
an	O
inherently	O
non-invertible	O
process	O
.	O
</s>
<s>
Video	B-Application
codec	I-Application
designs	O
are	O
usually	O
standardized	O
or	O
eventually	O
become	O
standardized	O
—	O
i.e.	O
,	O
specified	O
precisely	O
in	O
a	O
published	O
document	O
.	O
</s>
<s>
For	O
this	O
reason	O
,	O
the	O
quality	O
of	O
the	O
video	O
produced	O
by	O
decoding	O
the	O
results	O
of	O
different	O
encoders	O
that	O
use	O
the	O
same	O
video	B-Application
codec	I-Application
standard	O
can	O
vary	O
dramatically	O
from	O
one	O
encoder	O
implementation	O
to	O
another	O
.	O
</s>
<s>
A	O
variety	O
of	O
video	B-Algorithm
compression	I-Algorithm
formats	I-Algorithm
can	O
be	O
implemented	O
on	O
PCs	O
and	O
in	O
consumer	O
electronics	O
equipment	O
.	O
</s>
<s>
It	O
is	O
therefore	O
possible	O
for	O
multiple	O
codecs	B-General_Concept
to	O
be	O
available	O
in	O
the	O
same	O
product	O
,	O
reducing	O
the	O
need	O
to	O
choose	O
a	O
single	O
dominant	O
video	B-Algorithm
compression	I-Algorithm
format	I-Algorithm
to	O
achieve	O
interoperability	O
.	O
</s>
<s>
Standard	O
video	B-Algorithm
compression	I-Algorithm
formats	I-Algorithm
can	O
be	O
supported	O
by	O
multiple	O
encoder	O
and	O
decoder	O
implementations	O
from	O
multiple	O
sources	O
.	O
</s>
<s>
For	O
example	O
,	O
video	O
encoded	O
with	O
a	O
standard	O
MPEG-4	B-Application
Part2	O
codec	B-General_Concept
such	O
as	O
Xvid	O
can	O
be	O
decoded	O
using	O
any	O
other	O
standard	O
MPEG-4	B-Application
Part2	O
codec	B-General_Concept
such	O
as	O
FFmpeg	O
MPEG-4	B-Application
or	O
DivX	O
Pro	O
Codec	B-General_Concept
,	O
because	O
they	O
all	O
use	O
the	O
same	O
video	O
format	O
.	O
</s>
<s>
Codecs	B-General_Concept
have	O
their	O
qualities	O
and	O
drawbacks	O
.	O
</s>
<s>
The	O
trade-off	O
between	O
compression	O
power	O
,	O
speed	O
,	O
and	O
fidelity	O
(	O
including	O
artifacts	B-Algorithm
)	O
is	O
usually	O
considered	O
the	O
most	O
important	O
figure	O
of	O
technical	O
merit	O
.	O
</s>
<s>
Online	O
video	O
material	O
is	O
encoded	O
by	O
a	O
variety	O
of	O
codecs	B-General_Concept
,	O
and	O
this	O
has	O
led	O
to	O
the	O
availability	O
of	O
codec	B-General_Concept
packs	I-General_Concept
—	O
a	O
pre-assembled	O
set	O
of	O
commonly	O
used	O
codecs	B-General_Concept
combined	O
with	O
an	O
installer	O
available	O
as	O
a	O
software	O
package	O
for	O
PCs	O
,	O
such	O
as	O
K-Lite	B-Application
Codec	I-Application
Pack	I-Application
,	O
Perian	B-Operating_System
and	O
Combined	B-Application
Community	I-Application
Codec	I-Application
Pack	I-Application
.	O
</s>
