@@ -99,7 +99,7 @@ enum CornerRefineMethod{
9999 * - maxMarkerPerimeterRate: determine maximum perimeter for marker contour to be detected. This
100100 * is defined as a rate respect to the maximum dimension of the input image (default 4.0).
101101 * - polygonalApproxAccuracyRate: minimum accuracy during the polygonal approximation process to
102- * determine which contours are squares.
102+ * determine which contours are squares. (default 0.03)
103103 * - minCornerDistanceRate: minimum distance between corners for detected markers relative to its
104104 * perimeter (default 0.05)
105105 * - minDistanceToBorder: minimum distance of any corner to the image border for detected markers
@@ -109,18 +109,18 @@ enum CornerRefineMethod{
109109 * of the two markers (default 0.05).
110110 * - cornerRefinementMethod: corner refinement method. (CORNER_REFINE_NONE, no refinement.
111111 * CORNER_REFINE_SUBPIX, do subpixel refinement. CORNER_REFINE_CONTOUR use contour-Points,
112- * CORNER_REFINE_APRILTAG use the AprilTag2 approach)
112+ * CORNER_REFINE_APRILTAG use the AprilTag2 approach). (default CORNER_REFINE_NONE)
113113 * - cornerRefinementWinSize: window size for the corner refinement process (in pixels) (default 5).
114114 * - cornerRefinementMaxIterations: maximum number of iterations for stop criteria of the corner
115115 * refinement process (default 30).
116116 * - cornerRefinementMinAccuracy: minimum error for the stop cristeria of the corner refinement
117117 * process (default: 0.1)
118118 * - markerBorderBits: number of bits of the marker border, i.e. marker border width (default 1).
119- * - perpectiveRemovePixelPerCell : number of bits (per dimension) for each cell of the marker
120- * when removing the perspective (default 8 ).
119+ * - perspectiveRemovePixelPerCell : number of bits (per dimension) for each cell of the marker
120+ * when removing the perspective (default 4 ).
121121 * - perspectiveRemoveIgnoredMarginPerCell: width of the margin of pixels on each cell not
122122 * considered for the determination of the cell bit. Represents the rate respect to the total
123- * size of the cell, i.e. perpectiveRemovePixelPerCell (default 0.13)
123+ * size of the cell, i.e. perspectiveRemovePixelPerCell (default 0.13)
124124 * - maxErroneousBitsInBorderRate: maximum number of accepted erroneous bits in the border (i.e.
125125 * number of allowed white bits in the border). Represented as a rate respect to the total
126126 * number of bits per marker (default 0.35).
@@ -129,21 +129,23 @@ enum CornerRefineMethod{
129129 * than 128 or not) (default 5.0)
130130 * - errorCorrectionRate error correction rate respect to the maximun error correction capability
131131 * for each dictionary. (default 0.6).
132- * - aprilTagMinClusterPixels: reject quads containing too few pixels.
133- * - aprilTagMaxNmaxima: how many corner candidates to consider when segmenting a group of pixels into a quad.
132+ * - aprilTagMinClusterPixels: reject quads containing too few pixels. (default 5)
133+ * - aprilTagMaxNmaxima: how many corner candidates to consider when segmenting a group of pixels into a quad. (default 10)
134134 * - aprilTagCriticalRad: Reject quads where pairs of edges have angles that are close to straight or close to
135- * 180 degrees. Zero means that no quads are rejected. (In radians).
135+ * 180 degrees. Zero means that no quads are rejected. (In radians) (default 10*PI/180)
136136 * - aprilTagMaxLineFitMse: When fitting lines to the contours, what is the maximum mean squared error
137137 * allowed? This is useful in rejecting contours that are far from being quad shaped; rejecting
138- * these quads "early" saves expensive decoding processing.
138+ * these quads "early" saves expensive decoding processing. (default 10.0)
139139 * - aprilTagMinWhiteBlackDiff: When we build our model of black & white pixels, we add an extra check that
140- * the white model must be (overall) brighter than the black model. How much brighter? (in pixel values, [0,255]).
141- * - aprilTagDeglitch: should the thresholded image be deglitched? Only useful for very noisy images
140+ * the white model must be (overall) brighter than the black model. How much brighter? (in pixel values, [0,255]). (default 5)
141+ * - aprilTagDeglitch: should the thresholded image be deglitched? Only useful for very noisy images. (default 0)
142142 * - aprilTagQuadDecimate: Detection of quads can be done on a lower-resolution image, improving speed at a
143143 * cost of pose accuracy and a slight decrease in detection rate. Decoding the binary payload is still
144- * done at full resolution.
144+ * done at full resolution. (default 0.0)
145145 * - aprilTagQuadSigma: What Gaussian blur should be applied to the segmented image (used for quad detection?)
146- * Parameter is the standard deviation in pixels. Very noisy images benefit from non-zero values (e.g. 0.8).
146+ * Parameter is the standard deviation in pixels. Very noisy images benefit from non-zero values (e.g. 0.8). (default 0.0)
147+ * - detectInvertedMarker: to check if there is a white marker. In order to generate a "white" marker just
148+ * invert a normal marker by using a tilde, ~markerImage. (default false)
147149 */
148150struct CV_EXPORTS_W DetectorParameters {
149151
@@ -183,6 +185,9 @@ struct CV_EXPORTS_W DetectorParameters {
183185 CV_PROP_RW float aprilTagMaxLineFitMse;
184186 CV_PROP_RW int aprilTagMinWhiteBlackDiff;
185187 CV_PROP_RW int aprilTagDeglitch;
188+
189+ // to detect white (inverted) markers
190+ CV_PROP_RW bool detectInvertedMarker;
186191};
187192
188193
@@ -257,7 +262,7 @@ CV_EXPORTS_W void estimatePoseSingleMarkers(InputArrayOfArrays corners, float ma
257262/* *
258263 * @brief Board of markers
259264 *
260- * A board is a set of markers in the 3D space with a common cordinate system.
265+ * A board is a set of markers in the 3D space with a common coordinate system.
261266 * The common form of a board of marker is a planar (2D) board, however any 3D layout can be used.
262267 * A Board object is composed by:
263268 * - The object points of the marker corners, i.e. their coordinates respect to the board system.
@@ -268,7 +273,7 @@ class CV_EXPORTS_W Board {
268273
269274 public:
270275 /* *
271- * @brief Provide way to create Board by passing nessesary data. Specially needed in Python.
276+ * @brief Provide way to create Board by passing necessary data. Specially needed in Python.
272277 *
273278 * @param objPoints array of object points of all the marker corners in the board
274279 * @param dictionary the dictionary of markers employed for this board
@@ -292,7 +297,7 @@ class CV_EXPORTS_W Board {
292297
293298/* *
294299 * @brief Planar board with grid arrangement of markers
295- * More common type of board. All markers are placed in the same plane in a grid arrangment .
300+ * More common type of board. All markers are placed in the same plane in a grid arrangement .
296301 * The board can be drawn using drawPlanarBoard() function (@sa drawPlanarBoard)
297302 */
298303class CV_EXPORTS_W GridBoard : public Board {
@@ -349,7 +354,7 @@ class CV_EXPORTS_W GridBoard : public Board {
349354 // number of markers in X and Y directions
350355 int _markersX, _markersY;
351356
352- // marker side lenght (normally in meters)
357+ // marker side length (normally in meters)
353358 float _markerLength;
354359
355360 // separation between markers in the grid
@@ -387,8 +392,8 @@ class CV_EXPORTS_W GridBoard : public Board {
387392 * Note that returning a 0 means the pose has not been estimated.
388393 */
389394CV_EXPORTS_W int estimatePoseBoard (InputArrayOfArrays corners, InputArray ids, const Ptr<Board> &board,
390- InputArray cameraMatrix, InputArray distCoeffs, OutputArray rvec,
391- OutputArray tvec, bool useExtrinsicGuess = false );
395+ InputArray cameraMatrix, InputArray distCoeffs, InputOutputArray rvec,
396+ InputOutputArray tvec, bool useExtrinsicGuess = false );
392397
393398
394399
@@ -471,6 +476,8 @@ CV_EXPORTS_W void drawDetectedMarkers(InputOutputArray image, InputArrayOfArrays
471476 *
472477 * Given the pose estimation of a marker or board, this function draws the axis of the world
473478 * coordinate system, i.e. the system centered on the marker/board. Useful for debugging purposes.
479+ *
480+ * @deprecated use cv::drawFrameAxes
474481 */
475482CV_EXPORTS_W void drawAxis (InputOutputArray image, InputArray cameraMatrix, InputArray distCoeffs,
476483 InputArray rvec, InputArray tvec, float length);
0 commit comments