The essential difference between MJPEG and H.264 video compression methods is the algorithms used. The MJPEG image is compressed sequentially, frame by frame, and it is transmitted like that through the network. Each transmitted frame is processed independently, so it is sent frame by frame to the destination and then connected into one flawless video. Positive features are the ease of compression and processing speed. Such compression does not require extensive coding and decoding resources. Negative – high video resolution requires huge amount of data transferred, which raises the requirements of network bandwidth and the size of video archive.
So it seems that the benefits of H.264 compression method are obvious, so why still we need MJPEG?
H.264 considerations
As for video surveillance systems, system requirements should be defined and planned as precise as possible. Not in all cases the H.264 advantages are significant. Normally a video surveillance’s goal is visual confirmation of some event (or lack of it) with the ability to identify objects involved in it (identifying people, reading vehicle plate numbers and etc.). In case of general observation identification is not necessary, but when the video becomes evidence in a court or other institutions you need highest possible quality, so sometimes it is worth paying more for Ethernet traffic or bigger capacity of hard drives for the belief that the necessary information will be transmitted and recorded.
The most common problem in the design and implementation of systems with H.264 format cameras is prediction of the amount of network data rate. It can fluctuate in quite large range, depending on the intensity of image change, environmental conditions and camera features. Usually the average data rate is selected or sometimes even worse- the needed minimum, and on that basis required network bandwidth and archive size is calculated. Worst case happens when bandwith limits for camera are set on that calculated minimum values basis. In case of a radical change of image and the need to transfer larger amounts of data, depending on camera settings it has two alternatives: a) reduce image quality (resolution), b) reduce the number of frames. Both of these actions will reduce image quality and instead of the expected result you will get a low quality video. Practice shows that in most situations exactly that video record is needed for evaluation.
Factors affecting the size of the H.264 stream can be various: rain, snow, strong wind, low illumination (especially important for cameras that have a lower noise reduction or sensitivity) or the camera mounting instability. In all of these cases it is needed to calculate what maximum bandwidth will be achieved and on that basis it is recommended to plan your storage and network traffic. Another option can be choosing MJPEG format, which bandwidth is more predictable and varies in small range.
H.264 profiles
As for H.264, it should be noted that this standard is very broad and includes many tools and features that can be used or not. The mere mention of the H.264 in specifications not always guarantees all of advantages offered by this format. According to these properties there are several sets of H.264 profiles: baseline (Baseline Profile, BP), extended (Extended Profile, ET), main (Main Profile, MP) and high (High Profile, HiP), each of these can be divided further in details. BP profile is mainly used for video conferences and in mobile devices, where high compression is necessary and where devices have limited computing resources. MP profile has been used in standard-definition digital TV broadcasts and other video applications which require good image quality and data compression rate. HiP profile is used for high-definition digital television broadcasts, as well as video recording and playback of HD DVD and Blue Ray format files. Most of the IP video surveillance camera manufacturers use the BP profile, and only the few, including IQinVision – MP (main profile). MP profile for video compression ensures excellent image quality and reduces Ethernet data bandwidth (compared to MJPEG).
Recommended fields of application – video surveillance in a friendly environment, where significant image resolution and a large number of frames per second are needed, and also in situations when an audio recording or two-way audio communication is needed, benefits of this format are particularly clear in such cases.