When balancing JPEG image quality and frame rate on Ladybug cameras, there are two primary factors to consider:
- Compression Control—The rate at which the Ladybug compression engine works. A higher compression rate produces higher-quality JPEG images. In turn, higher-quality images result in larger amounts of data that must be transmitted to the PC.
- Image Buffer Size—The size of the frame buffer on the PC (controlled by the camera driver) that receives images from the camera. A larger buffer size means higher-quality data can be processed. However, processing more data may come at the expense of frame rate.
You can use the Ladybug Settings dialog of the Camera Control window in the LadybugCapPro program to adjust compression control and buffer size, effectively balancing the quality of JPEG images that are transmitted from a Ladybug camera with the frame rate of these transmissions. There are two primary mechanisms: auto and manual.
Compression Control in the Ladybug Settings dialog
For more information about working in the Ladybug Settings dialog of the LadybugCapPro program, refer to the ‘Ladybug Settings’ topic in the Ladybug SDK Help.
We recommend following these general guidelines:
- Maximize frame rate by setting Packet Size to the maximum allowed by the bus which is 32000 bytes for USB 3.1.
- Packet size is adjusted on the Custom Video Modes dialog of the Camera Control window in LadybugCapPro.
- A JPEG Quality setting up to 80%. The visual improvement at higher than 80% is negligible compared to the increased amount of data generated.
Adjusting JPEG Quality Manually
When JPEG Quality-Auto is not enabled, you can adjust the JPEG Quality value manually.
A JPEG Quality setting up to 80% is recommended.
When manually set, the JPEG Quality may be too high for your image size, frame rate or packet size settings. If this is the case, you may get unexpected results from your camera, including dropped frames and ‘Buffer too small’ errors displayed on the LadybugCapPro status bar. Depending on your requirements, you can address this by increasing the image buffer size, lowering the frame rate, or lowering image quality.
Adjusting JPEG Quality Automatically
When JPEG Quality-Auto is enabled, you can adjust the Auto Buffer Usage setting. This control specifies the percentage of the image buffer size that is actually used for JPEG compressed image data. Specifying a value less than the maximum allows for room in the image buffer to accommodate extra image data, depending on scene variations from frame to frame. Increasing this value may result in an increase in the JPEG Quality setting.
A Buffer Usage setting between 80% and 95% is recommended.
Enabling JPEG Quality-Auto means that the compression rate continually adjusts so that it never exceeds the amount of data allowed by the image buffer size. However it may result in images that are larger than necessary.
When JPEG Quality-Auto is not enabled, the percentage of the image buffer that is used cannot be controlled.