This function uses a checkerboard at different positions and angles within a stereo camera setup to estimate DLT calibration coefficients for use in stereo reconstruction. This function is a wrapper for the function dltCalibrateCameras
.
calibrateCameras(img.dir, sq.size, nx, ny, cal.file, corner.dir,
print.progress = TRUE, flip.view = FALSE, verify.dir = NULL,
error.dir = NULL, min.views = 'max', exec.dir = NULL,
undistort = FALSE, num.aspects.read = 'auto',
num.sample.est = 'auto', num.sample.sets = 'auto',
num.aspects.sample = 'auto', max.sample.optim = 30, nlm.calls.max = 20,
fit.min.break = 1, objective.min = 1, objective.min.break = 5,
with.circles = FALSE, sample.est = NULL, ...)
folder containing images of the checkerboard pattern, separated into separate folders by view.
character string indicating size of checkerboard squares (length along one dimension) including the unit of measure (e.g. '6.35 mm').
integer indicating the number of internal corners along one dimension of the checkerboard.
integer indicating the number of internal corners along the other dimension of the checkerboard.
file path to the output calibration file (if it does not already exist one will be created).
folder where the detected checkerboard corners will be saved (if it does not already exist one will be created).
logical indicating whether function processes should be printed to the console.
logical indicating whether one camera view is upside-down relative to the other.
folder where the images of the checkerboards with detected corners overlaid will be written (if it does not already exist one will be created).
folder where the error diagnostic plots will be saved (if it does not already exist one will be created).
integer indicating the minimum views in which corners must be detected in order to use in coefficient estimation. If set to 'max' (default) this will be equal to the number of input views.
file path to folder containing external executables for reading video files (still under development).
logical indicating whether to estimate lens distortion correction coefficients (still under development).
number (integer) of frames to be read from video input. Requires external executables (still under development).
number (integer) of aspects from total that will be sampled calibration coefficient estimation.
number (integer) of unique sets of aspects to try.
number (integer) of aspects to sample for each set.
maximum number (integer) of aspects to be used in identifying the best DLT coefficient set (once already estimated).
maximum number (integer) of different sets of random starting parameters to use during coefficient optimization. This parameter cannot exceed 576.
minimum error at which resampleGridImagePoints()
will stop iterating to find a better fit.
minimum error at which optimization will stop estimating the position of additional checkerboards.
The expected mean reconstruction error when optimizing the calibration coefficients (the minimum, or objective
value returned by nlminb()
). A value between 0.2 and 1.2 should be reasonable.
logical indicating whether the checkerboard pattern includes concentric circles for identifying the starting corner. Requires external executables (still under development).
vector of explicitly defined aspects to use in coefficient estimation.
further arguments to be passed to dltCalibrateCameras
.
a list of class "calibrateCameras"
with the following elements:
a matrix of 11 optimized DLT calibration coefficients per camera view.
the RMS error when coor.2d
and the optimized calibration coefficients cal.coeff
are input to dltReconstruct
.
the RMS error when coor.2d
and the optimized 3D coordinates coor.3d
are input to dltCoefficients
.
Please see StereoMorph tutorials for step-by-step tutorials on how to use StereoMorph for 2D or 3D shape data collection.
For a general overview of DLT: http://kwon3d.com/theory/dlt/dlt.html