Video Quality / Compression Tutorial

By IPVM Team, Published Oct 17, 2018, 09:02am EDT

While CODECs, like H.264, H.265, and MJPEG, get a lot of attention, a camera's 'quality' or compression setting has a big impact on overall quality. In this training, we explain what this level is, what options you have and how you should optimize it.

To start, review these two images, (A) and (B):

IPVM Image

And answer this question before continuing:

With the information presented, the best answer is that it cannot be determined. We used the same camera for each image and simply increased compression for the 'B' image (while keeping everything else the same, including resolution and codec).

The fact that two exact shots with the same resolution can look significantly different has a number of important implications. Inside, we explain why, covering:

  • Quantization levels
  • Bandwidth vs. quality loss
  • Image quality examples
  • Manufacturer differences
  • MBR/VBR/CBR impact
  • Smart codec impact
  • Recommendations

Quantization Levels

Regardless of codec used (H.264, H.265, MJPEG, etc.), all IP cameras offer quality levels, often called 'compression' or 'quantization'.

H.264 and H.265 quantization is measured on a standard scale ranging from 0 to 51, with lower numbers meaning less compression, and thus higher quality. If this seems counter intuitive to you, it is understandable, but these are simply the measurements defined in H.264 and H.265 standards.

IPVM Image

Key Tradeoff: Bandwidth Vs. Quality Loss

The key tradeoff in setting quantization is determining how much 'loss' you are willing to accept for a particular decrease in bandwidth. All production surveillance video compression is 'lossy', meaning that some information will be lost when video is compressed, making a crucial configuration decision:

  • ******** ***********/***** *** ******* level *** *** **** on *********, *** ****** quality.
  • ******** *******/****** *********** *** you *** **** ****** details, *** *** **** bandwidth *** ****** ******* time.

Demonstrated ** ********

*** ***** ***** ***** the ****** ** ******** quality ******. ** ***** to **** ****, ** took ******** **** *** scenes (****** / ****** and ******* / *******) and ******** *******. *** quantization ****** *** ** seen ********** ** **** scenes ** ******* **** up. *********, ***** ******* increases, **** **** ********** and ******** ** *******.

IPVM Image

Manufacturer **********

*** ************* *** ******* quality ******. **** ** you ***** ***** ***** settings, *** ************ **** make * ****** *** you. *******, **** *** vast ******** ** ************ cameras, ************* ******* *** available ** *** ******** users ****** ****.

*****, ** **** ** a *** ************* ** better *********** ***** **********. However, ******* ****** *** our** ****** ************ *********** Comparison**** *** **** ******* of **+ ************* *********** scales *** *** ** default ***** ******* ** "average" ***********. ** ******* from ****:

IPVM Image

Axis *** **. *** *** *********

**** **** *** ********* web **********. **** ******* cameras *** *** ********** ***** ******* *** **** *********** and **** *** ******* browser ******* *** *.***/*.*** video. **** *** *** old *** *** ***** to ******* ** "***********", with ****** ******* ***** more **********/***** *********. ****** of ****, ** ************* users *** ****** ******** the ***** ******** ** increases ***** *******.

*** *** *** ********* uses * ******/****** *****:

IPVM Image

***** *** *** ********* simply ****** **** *****:

IPVM Image

********** ** ***** ** is ****, **** *********** 30 ******* ** ~** on *** ************ *****.

*****

*****'* ***** ***** ***** quantization ** *-******, **** I-frames ******* ** **** by * ******** ****** ("I/P-frame ***** **" *****). So ** *-****** *** set ** ** *** I-frames *** ** -*, I-frames **** *** * minimum ** ** ************. This ***** ** ******** to ******* ************ ** a ******** *****, ********* some ***** *** ***** in * ***** ***** to ******.

IPVM Image

*********

*********'* *********** ******** *** under *** *****/***** ***, on * ***** ** "lowest" (**** ***********) ** "highest" (***** ***********), ********** to "******." ***** ******** are ****** ** ******** quantization ******, ******* **** ~20-35. ***** ******** *** corresponding ************ ****** *** the **** ***** **** H.264 *** *.***.

IPVM Image

Important: ***/***/*** ******

**** ************ *********** *** variable *** **** ********* (VBR), ***** ****** ********* in ***** ** ******** a ***-*** ******* *****, sometimes **** * ******* bit **** *** (****** MBR). *** ****** *** above ****** *** ************ level *** ****** ** targeting, *.*., ** **** camera **** ****** ************ level **, **** ******* increasing *** ********** ** necessary.

*******, ** ******* *** set ** ******** *** rate, ******* ***** ** NOT ************ ******* *** bit ****, ** ********** is '********', **** ******* level ************* ******** ** keep ********* *** ****. For ********, ** *** have * *** ***** stream *** ** ***/* looking ** * ***** wall, *** ****** *** use * '****' ******* level ***** ** ** easy ** ********. *******, if *** ****** *** turned *** *** * hand ** ***** ** front ** *** ******, it *** **** ** drop **** ** '***' quality ** ******** *** same ***/* ******** *** rate ** *********** ** more *********.

*** **** ** *** key ****** ** ***** streaming *****, *** ****** ** *** ** MBR - ************ *****************.

Smart ***** ******

***** ************ ******** *** ************ level ****** ********* ***** of *** ***** / frame / *****. ************, a ****** ************ ***** was **** *** ** entire *****. **** ***** codecs, *** ****** ************* between *** **********, ********* it * ****** ************ (thereby ********* **** *********) vs ******* **** * lower ************ *****.

** ** *******, * person ******* **** * hallway **** ** ****** quality, ***** *** ********** is ***** *******. *** aim ** ******** ******* bandwidth ***** *********** ******* for ********* *******.

IPVM Image

*******, ** ******** ********* readers **** ***** ****** in *** ***** ***** the ****** **** ** installed, ** **** ******** image ******* ******* *** be ****. *** *******, in *** ** *** tests, ****** ****** ** smart ***** ******** ****** blurring/smearing/artifacts ** *** *****, visible ** *** ******* and ********** *****. ******** should ** ********* ******** to ***** ***** ******.

******* ****** **** *** our***** ***** ******** **** *********** ** these *** ***** **************.

What ****** *** ***?

**********, *** **** ********* question **: **** ******* setting ** ********* ** the ******'* ***********?

*************, ** ** ********** to **** * ********* answer **:

  • *** ***** ***** ** a ********** ******** ****. Changing **** * ************ level ** ** ** 29 ** **** ** to ** ******** ** magical **********. ***** *** changes *** ****** ************* and *********.
  • *** ***** ***** ******* on *** ********** ** the *****. **** ******* scenes (**** ** ************) will ********* ******* **** a ****** ******* ****** than * ****** ***** (like * *********). *** smaller *** ******** ***** observed (**** * ****** across ** ************), *** more ****** ******* ****** can ******* ********** *******.

*******, ***** ***** *****, ** ***** *** key ***************:

  • ************ ~** ** *** "sweet ****":***** ** ***** ** ongoing *******, ** **** found ** ** ***** the **** ********* ******* bandwidth *** ***** *******. Many ************* ******* ** 28-30, ****** ***** ****** see ***** ****** ************ *********** Comparison*** **** ******* ** how ** *********** ******.
  • *** ***** ****** (*** carefully):******* ** ***** ******* bitrate ********** ** **** scenes, ** ********* ***** codecs ** **** ******** possible, ** ***** *** be **** ** ******** image ******* ***** *********, while ******** ****** ***** than ******* ******.

[[****: **** **** *** originally ******* ** **** but ************* ******* ** 2015-2020 ** ******* ******* codec *******, ***** ***** usage, *** ** ** date ***************]]

Comments (4)

You also have gone from macroblocks to more precise coding tree units and blocks. This allows more precise prediction units. There are also more degrees which the vectors of blocks can translate. 

 

but that zipstream though...

I think compression bit-rate is important however I think Quality and high bit rate from the camera to the HD is more important. I say this because when something happens and they need to review the incident they will review it that night or the next day. They need high quality picture to view. You need not worry about HD capacity at that time.

Quantization level plays an important role in image quality and clarity, smart codecs does not appear to be a feature one would activate as the norm given its haphazard application in its operation to me. The 'sweet spot of 28' should be adhered.

Read this IPVM report for free.

This article is part of IPVM's 6,733 reports, 908 tests and is only available to members. To get a one-time preview of our work, enter your work email to access the full article.

Already a member? Login here | Join now
Loading Related Reports