We are often asked about how much bandwidth is required by an IP camera system. It is a valid question, and one we are constantly reviewing.
Megapixel IP cameras generate quite a lot of data. The latest 4K cameras will generate even more; requiring more video storage, and more network resources.
It is important to understand what contributes to the bandwidth, and what steps can be taken to control it. This article describes the various compression schemes, the factors that affect bandwidth, and the practical things you can do to reduce the bandwidth in your IP camera systems.
Raw data from a Video Frame
The raw data generated by a frame of video can be quite high. The higher the resolution, the more pixels are in an image, and of course, the higher the raw bandwidth. As an example, let’s consider the data generated by a frame from a typical 2 megapixel camera. Both the Samsung SNV-6084 and the Sony EM630 have 2.1 Megapixel sensors. Each pixel contains a lot of information.
A pixel is actually an element that is made up of 3 color combinations (red, blue, green) that combine to create the full color spectrum. Each color element is digitized to provide a range of intensity. We usually use 8 bits (1 byte), to create 256 ranges. So this means, each pixel contains 3 bytes or 24 bits of data. So one frame consists of 24 x 2.1 megapixels = 50.4 bits. If we wanted to send 10 frames per second, then we generate a raw bandwidth of 504 Megabits/sec.
Compression Concepts
In data signal processing, compression is the method of reducing the amount of data or bit rate required to describe information. The objective of good compression is to achieve the lowest bandwidth while maintaining some reasonable level of video quality. It’s kind of subjective.
The data (like a video frame) is compressed by the source (like a camera) and then decompressed at the receiving end (like the computer running Video Management Software). The challenge is to reduce the data required, and still allow the data to be recognizable when it is decompressed. There are two general forms of compression called lossless and lossy. As its name implies, lossless compression, which removes statistical redundancy, doesn’t remove any information. Lossy compression methods reduce the information content, but still allow the receiving end to recognize the information. Usually this works quite well when a person is viewing the results of the compression. For example, we can recognize the meaning of wrds evn whn sme of the leters ar misng.
IP Camera Compression
Cameras have imbedded computers that (among other things) compress the video data. Usually the better the compression, the more computer power is needed to implement it. You may have noticed that some cameras run very hot to the touch. This is because their little computers are working very hard to provide the best compression. Compression schemes used by IP cameras include M-JPEG, MPEG4, H.264, and H.265.
M-JPEG, was the first type of compression used by IP cameras. It compresses each frame of video. It requires the least amount of computer power, and is probably the most ubiquitous, allowing many different applications to use the video data. It works primarily by removing redundant information from the video. For example, if there is an area of blue that is the same for 25 pixels, the compression scheme indicates that there are 25 pixels that are all the same, rather than sending 25 pixels. An indoor scene where the walls are the same color, can be compressed quite a lot. But an outdoor scene, viewing many trees, can’t be effectively compressed.
M-JPEG provides about 10 x reduction in data, which means that 500 Mbps is reduced to about 50 Mbps.
MPEG4, was introduced in 1998. This lossy type of compression, added frame to frame compression. It dramatically improved compression by processing the changes in the video from one frame to the next. It captured all the information in the first frame and then sent only the information that changed in the next frame. For example, if you were looking at a parking lot and viewed a person walking (who occupied a very small part of the field of view), only the person walking was sent in the following frames, while the stationary cars were not retransmitted. This compression works very well when a small part of the field of view is changing, but is not very good if there is a scene where there is a lot of motion. For example, it doesn’t work too well when viewing a field of view that contains a crowd of people on a busy street.
MPEG4 achieved about 50 to 100 X reduction of data. It can vary quite a bit depending on the motion detected. As an average, we usually estimate that data rates of about 5 mbps can be achieved from a 2 Megapixel IP camera.
H.264 or MPEG4 part 10, was introduced in 2003. This compression scheme required much more computing power and provided additional algorithms that improved the data compression of IP camera video. H.264 introduced the concept of blocks of video and predicted the movement from frame to frame.
H.264 achieves 2X to 4X reduction of data over MPEG4. Again, this type of compression depends on the content of the video. The more things that are moving the less compression is achieved.
H.265 or High Efficiency Video Encoding, is the latest compression scheme. It was introduced in 2013. The latest revisions were completed in 2015, and there will be more to follow. It is not available yet in most cameras. It requires the highest computer performance.
H.265 is targeted at a reduction of 1000 X (depending on application). It has been shown to achieve about 30% bit rate reduction, when compared to H.264.
Factors that affect IP camera bandwidth
The bandwidth used by an IP camera depends on resolution, compression, frame rate, motion, and noise levels. It can be controlled by increasing loss and throttling the bandwidth at the camera.
Resolution of course is one of the major factors in bandwidth. The more pixels, the more data required. A 5 megapixel IP camera requires more bandwidth than a 1 Megapixel camera.
Frame rate is another contributor of bandwidth. If you send a frame 30 times per sec, it requires 10 X more bandwidth than a frame every 3 seconds.
Motion in the field of view affects the bandwidth. When using MPEG4, H.264, or H.265, the higher the percentage of motion in the field of view, the lower the overall compression. M-JPEG is not affected by motion, but is primarily sensitive to the complexity of each frame of video.
Video noise is very important factor in compression. As it gets darker, and the camera video amplifiers work harder, they generate noise. Noise is random and looks like motion to the compression algorithms. The more noise the less compression can be achieved.
Things you can do to reduce bandwidth
Reduce the frame rate to the minimum required. Don’t use 30 fps. Unless you are watching a very fast changing scene, like testing of rockets and explosions, you won’t need high frame rate. Smooth video can be achieved at frame rates as low as 10 fps. Sometimes the frame rate is affected by the network bandwidth. If you don’t have enough bandwidth, the frame rate will go down. This is usually seen when you try to view an IP camera over the Internet.
Select the right compression. Many cameras provide a choice of M-JPEG or H.264 (or MPEG4 or H.265). Some people feel that M-JPEG provides a better quality picture, but this is not universal. I have seen differences depending on the specific camera (and the CODEC). In general don’t use M-JPEG if you need to reduce the bandwidth as much as possible.
Crop the video. Some cameras allow you to crop the video so you can reduce the total video frame size. For example, if you crop the sky (which hopefully doesn’t have interesting video), then you can reduce the size of the frame.
Throttle the bit rate. In some cameras, you can control the maximum bandwidth limit. By throttling the bit rate, the video will become lossier. A number of the Axis, Samsung and Sony IP cameras have some form of bit rate control.
Reduce the compression. Sometimes you can reduce the compression and accept more loss in the video.
Utilize motion detection. Motion detection can be detected by the camera or by the software in the computer. By detecting motion at the camera, you can dramatically reduce the overall bandwidth and the storage required. Note that not all cameras include motion detection, so be careful when selecting the camera. If the camera only sends video when it detects motion, then the average bandwidth over a period of time is reduced.
Increase lighting at night. By increasing the light, you reduce the noise levels and consequently reduce the bandwidth.
Summary
IP camera bandwidth is determined by the resolution, frame rate, compression schemes and other factors. You can control the bandwidth by selecting the right compression, decreasing frame rate, increasing the lighting, and various other things.
If you need help determining how to control the bandwidth used by your IP Camera system, please contact us. We can be reached at 800-431-1658 (in the USA), and 914-944-3425 (everywhere else), or just use our contact form.