From Wikibooks, open books for an open world
< SwisTrack‎ | Components
Jump to: navigation, search


Camera calibration using an algorithm proposed by Tsai. We use it to transform the image coordinates in world coordinates. More information about it can be found in his paper : "An Efficient and Accurate Camera Calibration Technique for 3D Machine Vision", Roger Y. Tsai, Proceedings of IEEE Conference on Computer Vision and Pattern Recognition, Miami Beach, FL, 1986, pages 364-374." or on this website. The calibration code come from this website.

For a deformed image, TSAI is better than a purely linear second order calibration method. However, it is slower, and sometimes, when the camera axis is orthogonal the to setup plan, TSAI method can lead to error in computation and tremendous errors, and even crash of the method.

A good presentation of the parameters can be found here.

This component is different from CalibrationTSAI as it does not compute the parameters and load them from a xml file.

Tools to compute these parameters with matlab/octave are provided in calibrationTools/Matlab_Octave. The following files can be used:

  • computeTsaiCalibrationParameters.m: Compute the Tsai parameters from calibration points coordinates (coplanar calibration)
  • TsaiImage2World.m: Transform the image coordinates to world coordinates using the Tsai calibration parameters (It is the same implementation than the one used in this component)
  • WriteTSAICalibrationParametersXMLFile.m: Write a Tsai calibration parameters in the right format for the component.
  • WriteSwisTrackCalibrationXMLFile.m: Write calibration points to a xml file compatible with swisTrack
  • readSwisTrackCalibrationXMLFile.m: Read calibration points from a xml file compatible with swisTrack
  • optimizeSx.m: Search for the optimal value of sx for the calibration
  • computeError.m: Compute the calibration errors






Calib. Points[edit]

This file is not mandatory as they are not used to compute the calibration paramters. If provided, the component compute the calibration errors and write them in a log file. Path the XML file containing the calibration points. The file must have the following format:

<?xml version="1.0"?>

More points can be added in the same way as the two points in this example. A minimum of 5 non-collinear points is needed to compute the calibration.

Calib. Param.[edit]

Path the XML file containing the calibration parameters. The file must have the following format:

<?xml version="1.0"?>