Package boofcv.abst.fiducial.calib
Class CalibrationDetectorSquareGrid
java.lang.Object
boofcv.abst.fiducial.calib.CalibrationDetectorSquareGrid
- All Implemented Interfaces:
DetectSingleFiducialCalibration
public class CalibrationDetectorSquareGrid
extends Object
implements DetectSingleFiducialCalibration
Implementation of
DetectSingleFiducialCalibration
for square grid target types.-
Constructor Summary
ConstructorDescriptionCalibrationDetectorSquareGrid
(ConfigSquareGrid configDet, ConfigGridDimen configDimen) -
Method Summary
Modifier and TypeMethodDescriptionstatic List<Point2D_F64>
createLayout
(int numRows, int numCols, double squareWidth, double spaceWidth) Creates a target that is composed of squares.Returns the set of detected points from the most recent call toDetectSingleFiducialCalibration.process(GrayF32)
.int
Returns number of columns in the gridint
Returns number of rows in the gridReturns the layout of the calibration points on the targetint
Returns number of columns in calibration point gridint
Returns number of rows in calibration point gridboolean
Image processing for calibration target detectionvoid
setLensDistortion
(@Nullable LensDistortionNarrowFOV distortion, int width, int height) Explicitly handles lens distortion when detecting image features.
-
Constructor Details
-
CalibrationDetectorSquareGrid
-
-
Method Details
-
process
Description copied from interface:DetectSingleFiducialCalibration
Image processing for calibration target detection- Specified by:
process
in interfaceDetectSingleFiducialCalibration
- Parameters:
input
- Gray scale image containing calibration target- Returns:
- true if target was detected and false if not
-
createLayout
public static List<Point2D_F64> createLayout(int numRows, int numCols, double squareWidth, double spaceWidth) Creates a target that is composed of squares. The squares are spaced out and each corner provides a calibration point.- Parameters:
numRows
- Number of rows in calibration target. Must be odd.numCols
- Number of column in each calibration target. Must be odd.squareWidth
- How wide each square is. Units are target dependent.spaceWidth
- Distance between the sides on each square. Units are target dependent.- Returns:
- Target description
-
getDetectedPoints
Description copied from interface:DetectSingleFiducialCalibration
Returns the set of detected points from the most recent call toDetectSingleFiducialCalibration.process(GrayF32)
. Each time this function is invoked a new instance of the list and points is returned. No data reuse here.- Specified by:
getDetectedPoints
in interfaceDetectSingleFiducialCalibration
- Returns:
- List of detected points in row major grid order.
-
getLayout
Description copied from interface:DetectSingleFiducialCalibration
Returns the layout of the calibration points on the target- Specified by:
getLayout
in interfaceDetectSingleFiducialCalibration
- Returns:
- List of calibration points
-
setLensDistortion
public void setLensDistortion(@Nullable @Nullable LensDistortionNarrowFOV distortion, int width, int height) Description copied from interface:DetectSingleFiducialCalibration
Explicitly handles lens distortion when detecting image features. If used, features will be found in undistorted pixel coordinates- Specified by:
setLensDistortion
in interfaceDetectSingleFiducialCalibration
-
getAlgorithm
-
getGridRows
public int getGridRows()Returns number of rows in the grid- Returns:
- number of rows
-
getGridColumns
public int getGridColumns()Returns number of columns in the grid- Returns:
- number of columns
-
getPointRows
public int getPointRows()Returns number of rows in calibration point grid- Returns:
- number of rows
-
getPointColumns
public int getPointColumns()Returns number of columns in calibration point grid- Returns:
- number of columns
-