public class CalibrateMonoPlanar
extends java.lang.Object
Performs the full processing loop for calibrating a mono camera from a planar grid. A directory is specified that the images are read in from. Calibration points are detected inside the image and feed into the Zhang99 algorithm for parameter estimation.
Internally it supports status updates for a GUI and skips over bad images. Invoke functions in the following order:
configure(boolean, int, boolean)reset()addImage(boofcv.struct.image.GrayF32)process()getIntrinsic()Most 3D operations in BoofCV assume that the image coordinate system is right handed and the +Z axis is pointing out of the camera. In standard image coordinate the origin (0,0) is at the top left corner with +x going to the right and +y going down, then if it is right handed +z will be out of the image. However some times this pseudo standard is not followed and the y-axis needs to be inverted by setting isInverted to true.
| Modifier and Type | Field and Description |
|---|---|
protected DetectorFiducialCalibration |
detector |
protected java.util.List<ImageResults> |
errors |
protected boofcv.struct.calib.CameraPinholeRadial |
foundIntrinsic |
protected Zhang99ParamAll |
foundZhang |
protected java.util.List<CalibrationObservation> |
observations |
boolean |
verbose |
protected CalibrationPlanarGridZhang99 |
zhang99 |
| Constructor and Description |
|---|
CalibrateMonoPlanar(DetectorFiducialCalibration detector)
High level configuration
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
addImage(boofcv.struct.image.GrayF32 image)
Adds a new view of the calibration target and processes it.
|
static java.util.List<ImageResults> |
computeErrors(java.util.List<CalibrationObservation> observation,
Zhang99ParamAll param,
java.util.List<georegression.struct.point.Point2D_F64> grid)
After the parameters have been estimated this computes the error for each calibration point in
each image and summary error statistics.
|
void |
configure(boolean assumeZeroSkew,
int numRadialParam,
boolean includeTangential)
Specify calibration assumptions.
|
java.util.List<ImageResults> |
getErrors() |
boofcv.struct.calib.CameraPinholeRadial |
getIntrinsic() |
java.util.List<CalibrationObservation> |
getObservations() |
Zhang99ParamAll |
getZhangParam() |
static void |
printErrors(java.util.List<ImageResults> results)
Prints out error information to standard out
|
void |
printStatistics() |
boofcv.struct.calib.CameraPinholeRadial |
process()
After calibration points have been found this invokes the Zhang99 algorithm to
estimate calibration parameters.
|
void |
removeLatestImage()
Removes the most recently added image
|
void |
reset()
Resets internal data structures.
|
protected DetectorFiducialCalibration detector
protected CalibrationPlanarGridZhang99 zhang99
protected Zhang99ParamAll foundZhang
protected boofcv.struct.calib.CameraPinholeRadial foundIntrinsic
protected java.util.List<CalibrationObservation> observations
protected java.util.List<ImageResults> errors
public boolean verbose
public CalibrateMonoPlanar(DetectorFiducialCalibration detector)
detector - Target detection algorithm.public void configure(boolean assumeZeroSkew,
int numRadialParam,
boolean includeTangential)
assumeZeroSkew - If true then zero skew is assumed. Typically this will be true.numRadialParam - Number of radial parameters. Typically set to 2.includeTangential - If true it will estimate tangential distortion parameters.
Try false then truepublic void reset()
public boolean addImage(boofcv.struct.image.GrayF32 image)
image - Image of a calibration targetpublic void removeLatestImage()
public boofcv.struct.calib.CameraPinholeRadial process()
public void printStatistics()
public static java.util.List<ImageResults> computeErrors(java.util.List<CalibrationObservation> observation, Zhang99ParamAll param, java.util.List<georegression.struct.point.Point2D_F64> grid)
observation - Observed control point locationparam - Found calibration parameterspublic static void printErrors(java.util.List<ImageResults> results)
public java.util.List<CalibrationObservation> getObservations()
public java.util.List<ImageResults> getErrors()
public Zhang99ParamAll getZhangParam()
public boofcv.struct.calib.CameraPinholeRadial getIntrinsic()