Main Content

Prepare Camera and Capture Images

Camera Setup

To calibrate your camera, follow these rules and tips:

  • Capture the images with a fixed focus by disabling the autofocus of the camera. Set the focus of the camera for your application.

  • Place the calibration pattern at such a distance from the camera that at least 20% of the image is covered by pattern.

  • If capturing images using a stereo camera pair, place the pattern in different orientations such that it is fully visible from both cameras of the stereo camera pair.

  • Keep in mind that changing the zoom setting between images, changes the focal length.

Capture Images

For better results, use a minimum of 10 to 20 images of the calibration pattern. The calibrator requires at least three images. Use uncompressed images or images in lossless compression formats such as PNG. For greater calibration accuracy:

  • Capture the images of the pattern at a distance roughly equal to the distance from your camera to the objects of interest. For example, if you plan to measure objects from 2 meters, keep your pattern approximately 2 meters from the camera.

  • Place the pattern at an angle less than 45 degrees relative to the camera plane.

    Pattern at zero-to-forty-five degrees relative to the camera plane.

  • Do not modify the images For example, do not crop them.

  • Do not use autofocus or change the zoom settings between images.

  • Capture the images of the calibration pattern at different orientations relative to the camera. For more information on calibration patterns, see Calibration Patterns.

  • Capture a variety of images of the pattern to account for as much of the image frame as possible. Lens distortion increases radially from the center of the image, and is not always uniform across the image frame. To capture this lens distortion, the pattern must include areas near the edges of the captured images.

    Checkerboard pattern images, with the calibration pattern covering space near the edged of the images.

The calibrator works with a range of pattern sizes. As a general rule, your pattern should fill at least 20% of the captured image. For example, these images have been taken with a checkerboard square size of 108 mm:

On the left, a diagram of camera position relative to grouped checkeboard images. On the right, eight images of a checkerboard pattern in different orientations, taking up most of the image frame.