Revision 21/01/2020
Accuware Inc.

Dragonfly

Calibration App

This document describes the usage of the Calibration native application of Accuware Inc.

The Calibration App is a complete command-line program allowing to perform advanced camera calibration and is available for Linux (Ubuntu) and macOS. It is meant to be used when the Accuware Dragonfly Web Application appears to be too limited for the user camera or accuracy requirements.

This application is well suited for the calibration of custom stereo cameras.

Requirements

Run the Calibration App

Camera opening examples

In every cases, be careful to provide the --hdist value in meters.

Monocular

./CalibrationApp --webcam 0 --width 640 --height 480 --hdist 0.182 --output my_file

Stereo camera

Single device (concatenated image) case:

./CalibrationApp --webcam 0 --width 640 --height 480 --split vertical --calib_left left.json --calib_right right.json --hdist 0.182 --output stereo

Dual devices (separated cameras) case:

./CalibrationApp --webcam 1 --webcam_right 2 --calib_left left.json --calib_right right.json --hdist 0.182 --output stereo

Commands

Here is the list of available actions when the camera is opened.

Command Action
P Take picture
ENTER Calibrate
Q Quit

How to calibrate

Here is a little explanation about how to properly calibrate a camera.

Good practices

Monocular calibration

In the monocular case, it is required to:

Usage example

./CalibrationApp --webcam 0 --width 640 --height 480 --hdist 0.182 --output my_file

Stereo calibration

The stereo calibration is tricky and longer to perform. It has to be very accurate, and it is highly recommended to follow the good practices described above.

First, it is required to perform a monocular calibration of the two cameras following the Monocular calibration instructions. Keep the two generated calibration files for the left and the right camera.

If you have a single device stereo camera with concatenated images, you can use the --split and --select options to calibrate each camera separately:

Usage example

./CalibrationApp --webcam 0 --width 640 --height 480 --split vertical --select left --hdist 0.182 --output left
./CalibrationApp --webcam 0 --width 640 --height 480 --split vertical --select right --hdist 0.182 --output right

Once the calibration file for both cameras is available, you can perform the stereo calibration by providing the two calibration files in option. At least 40 pictures are required.

Usage example

./CalibrationApp --webcam 0 --width 640 --height 480 --split vertical --calib_left left.json --calib_right right.json --hdist 0.182 --output stereo