View Source Evision.ArUco (Evision v0.1.38)

Summary

Types

t()

Type that represents an ArUco struct.

Functions

It's the same function as #calibrateCameraAruco but without calibration error estimation.

It's the same function as #calibrateCameraAruco but without calibration error estimation.

It's the same function as #calibrateCameraCharuco but without calibration error estimation.

It's the same function as #calibrateCameraCharuco but without calibration error estimation.

Draws a set of Charuco corners

Draw a set of detected ChArUco Diamond markers

Draw a set of detected ChArUco Diamond markers

Draw detected markers in image

Draw detected markers in image

Pose estimation for a ChArUco board given some of their corners

Extend base dictionary by new nMarkers

Extend base dictionary by new nMarkers

Generate a canonical marker image

Generate a canonical marker image

Returns one of the predefined dictionaries referenced by DICT_*.

Interpolate position of ChArUco board corners

Interpolate position of ChArUco board corners

Types

@type t() :: %Evision.ArUco{ref: reference()}

Type that represents an ArUco struct.

  • ref. reference()

    The underlying erlang resource variable.

Functions

Link to this function

calibrateCameraAruco(corners, ids, counter, board, imageSize, cameraMatrix, distCoeffs)

View Source

It's the same function as #calibrateCameraAruco but without calibration error estimation.

Positional Arguments
  • corners: [Evision.Mat]
  • ids: Evision.Mat.t()
  • counter: Evision.Mat.t()
  • board: Board
  • imageSize: Size
Keyword Arguments
  • flags: int.
  • criteria: TermCriteria.
Return
  • retval: double
  • cameraMatrix: Evision.Mat.t()
  • distCoeffs: Evision.Mat.t()
  • rvecs: [Evision.Mat].
  • tvecs: [Evision.Mat].

Has overloading in C++

Python prototype (for reference only):

calibrateCameraAruco(corners, ids, counter, board, imageSize, cameraMatrix, distCoeffs[, rvecs[, tvecs[, flags[, criteria]]]]) -> retval, cameraMatrix, distCoeffs, rvecs, tvecs
Link to this function

calibrateCameraAruco(corners, ids, counter, board, imageSize, cameraMatrix, distCoeffs, opts)

View Source

It's the same function as #calibrateCameraAruco but without calibration error estimation.

Positional Arguments
  • corners: [Evision.Mat]
  • ids: Evision.Mat.t()
  • counter: Evision.Mat.t()
  • board: Board
  • imageSize: Size
Keyword Arguments
  • flags: int.
  • criteria: TermCriteria.
Return
  • retval: double
  • cameraMatrix: Evision.Mat.t()
  • distCoeffs: Evision.Mat.t()
  • rvecs: [Evision.Mat].
  • tvecs: [Evision.Mat].

Has overloading in C++

Python prototype (for reference only):

calibrateCameraAruco(corners, ids, counter, board, imageSize, cameraMatrix, distCoeffs[, rvecs[, tvecs[, flags[, criteria]]]]) -> retval, cameraMatrix, distCoeffs, rvecs, tvecs
Link to this function

calibrateCameraArucoExtended(corners, ids, counter, board, imageSize, cameraMatrix, distCoeffs)

View Source

Calibrate a camera using aruco markers

Positional Arguments
  • corners: [Evision.Mat].

    vector of detected marker corners in all frames. The corners should have the same format returned by detectMarkers (see #detectMarkers).

  • ids: Evision.Mat.t().

    list of identifiers for each marker in corners

  • counter: Evision.Mat.t().

    number of markers in each frame so that corners and ids can be split

  • board: Board.

    Marker Board layout

  • imageSize: Size.

    Size of the image used only to initialize the intrinsic camera matrix.

Keyword Arguments
  • flags: int.

    flags Different flags for the calibration process (see #calibrateCamera for details).

  • criteria: TermCriteria.

    Termination criteria for the iterative optimization algorithm.

Return
  • retval: double

  • cameraMatrix: Evision.Mat.t().

    Output 3x3 floating-point camera matrix \f$A = \vecthreethree{f_x}{0}{c_x}{0}{f_y}{c_y}{0}{0}{1}\f$ . If CV_CALIB_USE_INTRINSIC_GUESS and/or CV_CALIB_FIX_ASPECT_RATIO are specified, some or all of fx, fy, cx, cy must be initialized before calling the function.

  • distCoeffs: Evision.Mat.t().

    Output vector of distortion coefficients \f$(k_1, k_2, p_1, p_2[, k_3[, k_4, k_5, k_6],[s_1, s_2, s_3, s_4]])\f$ of 4, 5, 8 or 12 elements

  • rvecs: [Evision.Mat].

    Output vector of rotation vectors (see Rodrigues ) estimated for each board view (e.g. std::vector<cv::Mat>>). That is, each k-th rotation vector together with the corresponding k-th translation vector (see the next output parameter description) brings the board pattern from the model coordinate space (in which object points are specified) to the world coordinate space, that is, a real position of the board pattern in the k-th pattern view (k=0.. M -1).

  • tvecs: [Evision.Mat].

    Output vector of translation vectors estimated for each pattern view.

  • stdDeviationsIntrinsics: Evision.Mat.t().

    Output vector of standard deviations estimated for intrinsic parameters. Order of deviations values: \f$(f_x, f_y, c_x, c_y, k_1, k_2, p_1, p_2, k_3, k_4, k_5, k_6 , s_1, s_2, s_3, s_4, \tau_x, \tau_y)\f$ If one of parameters is not estimated, it's deviation is equals to zero.

  • stdDeviationsExtrinsics: Evision.Mat.t().

    Output vector of standard deviations estimated for extrinsic parameters. Order of deviations values: \f$(R_1, T_1, \dotsc , R_M, T_M)\f$ where M is number of pattern views, \f$R_i, T_i\f$ are concatenated 1x3 vectors.

  • perViewErrors: Evision.Mat.t().

    Output vector of average re-projection errors estimated for each pattern view.

This function calibrates a camera using an Aruco Board. The function receives a list of detected markers from several views of the Board. The process is similar to the chessboard calibration in calibrateCamera(). The function returns the final re-projection error.

Python prototype (for reference only):

calibrateCameraArucoExtended(corners, ids, counter, board, imageSize, cameraMatrix, distCoeffs[, rvecs[, tvecs[, stdDeviationsIntrinsics[, stdDeviationsExtrinsics[, perViewErrors[, flags[, criteria]]]]]]]) -> retval, cameraMatrix, distCoeffs, rvecs, tvecs, stdDeviationsIntrinsics, stdDeviationsExtrinsics, perViewErrors
Link to this function

calibrateCameraArucoExtended(corners, ids, counter, board, imageSize, cameraMatrix, distCoeffs, opts)

View Source

Calibrate a camera using aruco markers

Positional Arguments
  • corners: [Evision.Mat].

    vector of detected marker corners in all frames. The corners should have the same format returned by detectMarkers (see #detectMarkers).

  • ids: Evision.Mat.t().

    list of identifiers for each marker in corners

  • counter: Evision.Mat.t().

    number of markers in each frame so that corners and ids can be split

  • board: Board.

    Marker Board layout

  • imageSize: Size.

    Size of the image used only to initialize the intrinsic camera matrix.

Keyword Arguments
  • flags: int.

    flags Different flags for the calibration process (see #calibrateCamera for details).

  • criteria: TermCriteria.

    Termination criteria for the iterative optimization algorithm.

Return
  • retval: double

  • cameraMatrix: Evision.Mat.t().

    Output 3x3 floating-point camera matrix \f$A = \vecthreethree{f_x}{0}{c_x}{0}{f_y}{c_y}{0}{0}{1}\f$ . If CV_CALIB_USE_INTRINSIC_GUESS and/or CV_CALIB_FIX_ASPECT_RATIO are specified, some or all of fx, fy, cx, cy must be initialized before calling the function.

  • distCoeffs: Evision.Mat.t().

    Output vector of distortion coefficients \f$(k_1, k_2, p_1, p_2[, k_3[, k_4, k_5, k_6],[s_1, s_2, s_3, s_4]])\f$ of 4, 5, 8 or 12 elements

  • rvecs: [Evision.Mat].

    Output vector of rotation vectors (see Rodrigues ) estimated for each board view (e.g. std::vector<cv::Mat>>). That is, each k-th rotation vector together with the corresponding k-th translation vector (see the next output parameter description) brings the board pattern from the model coordinate space (in which object points are specified) to the world coordinate space, that is, a real position of the board pattern in the k-th pattern view (k=0.. M -1).

  • tvecs: [Evision.Mat].

    Output vector of translation vectors estimated for each pattern view.

  • stdDeviationsIntrinsics: Evision.Mat.t().

    Output vector of standard deviations estimated for intrinsic parameters. Order of deviations values: \f$(f_x, f_y, c_x, c_y, k_1, k_2, p_1, p_2, k_3, k_4, k_5, k_6 , s_1, s_2, s_3, s_4, \tau_x, \tau_y)\f$ If one of parameters is not estimated, it's deviation is equals to zero.

  • stdDeviationsExtrinsics: Evision.Mat.t().

    Output vector of standard deviations estimated for extrinsic parameters. Order of deviations values: \f$(R_1, T_1, \dotsc , R_M, T_M)\f$ where M is number of pattern views, \f$R_i, T_i\f$ are concatenated 1x3 vectors.

  • perViewErrors: Evision.Mat.t().

    Output vector of average re-projection errors estimated for each pattern view.

This function calibrates a camera using an Aruco Board. The function receives a list of detected markers from several views of the Board. The process is similar to the chessboard calibration in calibrateCamera(). The function returns the final re-projection error.

Python prototype (for reference only):

calibrateCameraArucoExtended(corners, ids, counter, board, imageSize, cameraMatrix, distCoeffs[, rvecs[, tvecs[, stdDeviationsIntrinsics[, stdDeviationsExtrinsics[, perViewErrors[, flags[, criteria]]]]]]]) -> retval, cameraMatrix, distCoeffs, rvecs, tvecs, stdDeviationsIntrinsics, stdDeviationsExtrinsics, perViewErrors
Link to this function

calibrateCameraCharuco(charucoCorners, charucoIds, board, imageSize, cameraMatrix, distCoeffs)

View Source

It's the same function as #calibrateCameraCharuco but without calibration error estimation.

Positional Arguments
  • charucoCorners: [Evision.Mat]
  • charucoIds: [Evision.Mat]
  • board: Evision.ArUco.CharucoBoard.t()
  • imageSize: Size
Keyword Arguments
  • flags: int.
  • criteria: TermCriteria.
Return
  • retval: double
  • cameraMatrix: Evision.Mat.t()
  • distCoeffs: Evision.Mat.t()
  • rvecs: [Evision.Mat].
  • tvecs: [Evision.Mat].

Python prototype (for reference only):

calibrateCameraCharuco(charucoCorners, charucoIds, board, imageSize, cameraMatrix, distCoeffs[, rvecs[, tvecs[, flags[, criteria]]]]) -> retval, cameraMatrix, distCoeffs, rvecs, tvecs
Link to this function

calibrateCameraCharuco(charucoCorners, charucoIds, board, imageSize, cameraMatrix, distCoeffs, opts)

View Source

It's the same function as #calibrateCameraCharuco but without calibration error estimation.

Positional Arguments
  • charucoCorners: [Evision.Mat]
  • charucoIds: [Evision.Mat]
  • board: Evision.ArUco.CharucoBoard.t()
  • imageSize: Size
Keyword Arguments
  • flags: int.
  • criteria: TermCriteria.
Return
  • retval: double
  • cameraMatrix: Evision.Mat.t()
  • distCoeffs: Evision.Mat.t()
  • rvecs: [Evision.Mat].
  • tvecs: [Evision.Mat].

Python prototype (for reference only):

calibrateCameraCharuco(charucoCorners, charucoIds, board, imageSize, cameraMatrix, distCoeffs[, rvecs[, tvecs[, flags[, criteria]]]]) -> retval, cameraMatrix, distCoeffs, rvecs, tvecs
Link to this function

calibrateCameraCharucoExtended(charucoCorners, charucoIds, board, imageSize, cameraMatrix, distCoeffs)

View Source

Calibrate a camera using Charuco corners

Positional Arguments
  • charucoCorners: [Evision.Mat].

    vector of detected charuco corners per frame

  • charucoIds: [Evision.Mat].

    list of identifiers for each corner in charucoCorners per frame

  • board: Evision.ArUco.CharucoBoard.t().

    Marker Board layout

  • imageSize: Size.

    input image size

Keyword Arguments
  • flags: int.

    flags Different flags for the calibration process (see #calibrateCamera for details).

  • criteria: TermCriteria.

    Termination criteria for the iterative optimization algorithm.

Return
  • retval: double

  • cameraMatrix: Evision.Mat.t().

    Output 3x3 floating-point camera matrix \f$A = \vecthreethree{f_x}{0}{c_x}{0}{f_y}{c_y}{0}{0}{1}\f$ . If CV_CALIB_USE_INTRINSIC_GUESS and/or CV_CALIB_FIX_ASPECT_RATIO are specified, some or all of fx, fy, cx, cy must be initialized before calling the function.

  • distCoeffs: Evision.Mat.t().

    Output vector of distortion coefficients \f$(k_1, k_2, p_1, p_2[, k_3[, k_4, k_5, k_6],[s_1, s_2, s_3, s_4]])\f$ of 4, 5, 8 or 12 elements

  • rvecs: [Evision.Mat].

    Output vector of rotation vectors (see Rodrigues ) estimated for each board view (e.g. std::vector<cv::Mat>>). That is, each k-th rotation vector together with the corresponding k-th translation vector (see the next output parameter description) brings the board pattern from the model coordinate space (in which object points are specified) to the world coordinate space, that is, a real position of the board pattern in the k-th pattern view (k=0.. M -1).

  • tvecs: [Evision.Mat].

    Output vector of translation vectors estimated for each pattern view.

  • stdDeviationsIntrinsics: Evision.Mat.t().

    Output vector of standard deviations estimated for intrinsic parameters. Order of deviations values: \f$(f_x, f_y, c_x, c_y, k_1, k_2, p_1, p_2, k_3, k_4, k_5, k_6 , s_1, s_2, s_3, s_4, \tau_x, \tau_y)\f$ If one of parameters is not estimated, it's deviation is equals to zero.

  • stdDeviationsExtrinsics: Evision.Mat.t().

    Output vector of standard deviations estimated for extrinsic parameters. Order of deviations values: \f$(R_1, T_1, \dotsc , R_M, T_M)\f$ where M is number of pattern views, \f$R_i, T_i\f$ are concatenated 1x3 vectors.

  • perViewErrors: Evision.Mat.t().

    Output vector of average re-projection errors estimated for each pattern view.

This function calibrates a camera using a set of corners of a Charuco Board. The function receives a list of detected corners and its identifiers from several views of the Board. The function returns the final re-projection error.

Python prototype (for reference only):

calibrateCameraCharucoExtended(charucoCorners, charucoIds, board, imageSize, cameraMatrix, distCoeffs[, rvecs[, tvecs[, stdDeviationsIntrinsics[, stdDeviationsExtrinsics[, perViewErrors[, flags[, criteria]]]]]]]) -> retval, cameraMatrix, distCoeffs, rvecs, tvecs, stdDeviationsIntrinsics, stdDeviationsExtrinsics, perViewErrors
Link to this function

calibrateCameraCharucoExtended(charucoCorners, charucoIds, board, imageSize, cameraMatrix, distCoeffs, opts)

View Source

Calibrate a camera using Charuco corners

Positional Arguments
  • charucoCorners: [Evision.Mat].

    vector of detected charuco corners per frame

  • charucoIds: [Evision.Mat].

    list of identifiers for each corner in charucoCorners per frame

  • board: Evision.ArUco.CharucoBoard.t().

    Marker Board layout

  • imageSize: Size.

    input image size

Keyword Arguments
  • flags: int.

    flags Different flags for the calibration process (see #calibrateCamera for details).

  • criteria: TermCriteria.

    Termination criteria for the iterative optimization algorithm.

Return
  • retval: double

  • cameraMatrix: Evision.Mat.t().

    Output 3x3 floating-point camera matrix \f$A = \vecthreethree{f_x}{0}{c_x}{0}{f_y}{c_y}{0}{0}{1}\f$ . If CV_CALIB_USE_INTRINSIC_GUESS and/or CV_CALIB_FIX_ASPECT_RATIO are specified, some or all of fx, fy, cx, cy must be initialized before calling the function.

  • distCoeffs: Evision.Mat.t().

    Output vector of distortion coefficients \f$(k_1, k_2, p_1, p_2[, k_3[, k_4, k_5, k_6],[s_1, s_2, s_3, s_4]])\f$ of 4, 5, 8 or 12 elements

  • rvecs: [Evision.Mat].

    Output vector of rotation vectors (see Rodrigues ) estimated for each board view (e.g. std::vector<cv::Mat>>). That is, each k-th rotation vector together with the corresponding k-th translation vector (see the next output parameter description) brings the board pattern from the model coordinate space (in which object points are specified) to the world coordinate space, that is, a real position of the board pattern in the k-th pattern view (k=0.. M -1).

  • tvecs: [Evision.Mat].

    Output vector of translation vectors estimated for each pattern view.

  • stdDeviationsIntrinsics: Evision.Mat.t().

    Output vector of standard deviations estimated for intrinsic parameters. Order of deviations values: \f$(f_x, f_y, c_x, c_y, k_1, k_2, p_1, p_2, k_3, k_4, k_5, k_6 , s_1, s_2, s_3, s_4, \tau_x, \tau_y)\f$ If one of parameters is not estimated, it's deviation is equals to zero.

  • stdDeviationsExtrinsics: Evision.Mat.t().

    Output vector of standard deviations estimated for extrinsic parameters. Order of deviations values: \f$(R_1, T_1, \dotsc , R_M, T_M)\f$ where M is number of pattern views, \f$R_i, T_i\f$ are concatenated 1x3 vectors.

  • perViewErrors: Evision.Mat.t().

    Output vector of average re-projection errors estimated for each pattern view.

This function calibrates a camera using a set of corners of a Charuco Board. The function receives a list of detected corners and its identifiers from several views of the Board. The function returns the final re-projection error.

Python prototype (for reference only):

calibrateCameraCharucoExtended(charucoCorners, charucoIds, board, imageSize, cameraMatrix, distCoeffs[, rvecs[, tvecs[, stdDeviationsIntrinsics[, stdDeviationsExtrinsics[, perViewErrors[, flags[, criteria]]]]]]]) -> retval, cameraMatrix, distCoeffs, rvecs, tvecs, stdDeviationsIntrinsics, stdDeviationsExtrinsics, perViewErrors
Link to this function

detectCharucoDiamond(image, markerCorners, markerIds, squareMarkerLengthRate)

View Source
@spec detectCharucoDiamond(
  Evision.Mat.maybe_mat_in(),
  [Evision.Mat.maybe_mat_in()],
  Evision.Mat.maybe_mat_in(),
  number()
) :: {[Evision.Mat.t()], Evision.Mat.t()} | {:error, String.t()}

Detect ChArUco Diamond markers

Positional Arguments
  • image: Evision.Mat.t().

    input image necessary for corner subpixel.

  • markerCorners: [Evision.Mat].

    list of detected marker corners from detectMarkers function.

  • markerIds: Evision.Mat.t().

    list of marker ids in markerCorners.

  • squareMarkerLengthRate: float.

    rate between square and marker length: squareMarkerLengthRate = squareLength/markerLength. The real units are not necessary.

Keyword Arguments
  • cameraMatrix: Evision.Mat.t().

    Optional camera calibration matrix.

  • distCoeffs: Evision.Mat.t().

    Optional camera distortion coefficients.

  • dictionary: Dictionary.

    dictionary of markers indicating the type of markers.

Return
  • diamondCorners: [Evision.Mat].

    output list of detected diamond corners (4 corners per diamond). The order is the same than in marker corners: top left, top right, bottom right and bottom left. Similar format than the corners returned by detectMarkers (e.g std::vector<std::vector<cv::Point2f> > ).

  • diamondIds: Evision.Mat.t().

    ids of the diamonds in diamondCorners. The id of each diamond is in fact of type Vec4i, so each diamond has 4 ids, which are the ids of the aruco markers composing the diamond.

This function detects Diamond markers from the previous detected ArUco markers. The diamonds are returned in the diamondCorners and diamondIds parameters. If camera calibration parameters are provided, the diamond search is based on reprojection. If not, diamond search is based on homography. Homography is faster than reprojection, but less accurate. @deprecated Use CharucoDetector::detectDiamonds

Python prototype (for reference only):

detectCharucoDiamond(image, markerCorners, markerIds, squareMarkerLengthRate[, diamondCorners[, diamondIds[, cameraMatrix[, distCoeffs[, dictionary]]]]]) -> diamondCorners, diamondIds
Link to this function

detectCharucoDiamond(image, markerCorners, markerIds, squareMarkerLengthRate, opts)

View Source
@spec detectCharucoDiamond(
  Evision.Mat.maybe_mat_in(),
  [Evision.Mat.maybe_mat_in()],
  Evision.Mat.maybe_mat_in(),
  number(),
  [{atom(), term()}, ...] | nil
) :: {[Evision.Mat.t()], Evision.Mat.t()} | {:error, String.t()}

Detect ChArUco Diamond markers

Positional Arguments
  • image: Evision.Mat.t().

    input image necessary for corner subpixel.

  • markerCorners: [Evision.Mat].

    list of detected marker corners from detectMarkers function.

  • markerIds: Evision.Mat.t().

    list of marker ids in markerCorners.

  • squareMarkerLengthRate: float.

    rate between square and marker length: squareMarkerLengthRate = squareLength/markerLength. The real units are not necessary.

Keyword Arguments
  • cameraMatrix: Evision.Mat.t().

    Optional camera calibration matrix.

  • distCoeffs: Evision.Mat.t().

    Optional camera distortion coefficients.

  • dictionary: Dictionary.

    dictionary of markers indicating the type of markers.

Return
  • diamondCorners: [Evision.Mat].

    output list of detected diamond corners (4 corners per diamond). The order is the same than in marker corners: top left, top right, bottom right and bottom left. Similar format than the corners returned by detectMarkers (e.g std::vector<std::vector<cv::Point2f> > ).

  • diamondIds: Evision.Mat.t().

    ids of the diamonds in diamondCorners. The id of each diamond is in fact of type Vec4i, so each diamond has 4 ids, which are the ids of the aruco markers composing the diamond.

This function detects Diamond markers from the previous detected ArUco markers. The diamonds are returned in the diamondCorners and diamondIds parameters. If camera calibration parameters are provided, the diamond search is based on reprojection. If not, diamond search is based on homography. Homography is faster than reprojection, but less accurate. @deprecated Use CharucoDetector::detectDiamonds

Python prototype (for reference only):

detectCharucoDiamond(image, markerCorners, markerIds, squareMarkerLengthRate[, diamondCorners[, diamondIds[, cameraMatrix[, distCoeffs[, dictionary]]]]]) -> diamondCorners, diamondIds
Link to this function

detectMarkers(image, dictionary)

View Source

detect markers

Positional Arguments
  • image: Evision.Mat.t()
  • dictionary: Dictionary
Keyword Arguments
  • parameters: DetectorParameters.
Return
  • corners: [Evision.Mat].
  • ids: Evision.Mat.t().
  • rejectedImgPoints: [Evision.Mat].

@deprecated Use class ArucoDetector::detectMarkers

Python prototype (for reference only):

detectMarkers(image, dictionary[, corners[, ids[, parameters[, rejectedImgPoints]]]]) -> corners, ids, rejectedImgPoints
Link to this function

detectMarkers(image, dictionary, opts)

View Source
@spec detectMarkers(
  Evision.Mat.maybe_mat_in(),
  Evision.ArUco.Dictionary.t(),
  [{atom(), term()}, ...] | nil
) ::
  {[Evision.Mat.t()], Evision.Mat.t(), [Evision.Mat.t()]} | {:error, String.t()}

detect markers

Positional Arguments
  • image: Evision.Mat.t()
  • dictionary: Dictionary
Keyword Arguments
  • parameters: DetectorParameters.
Return
  • corners: [Evision.Mat].
  • ids: Evision.Mat.t().
  • rejectedImgPoints: [Evision.Mat].

@deprecated Use class ArucoDetector::detectMarkers

Python prototype (for reference only):

detectMarkers(image, dictionary[, corners[, ids[, parameters[, rejectedImgPoints]]]]) -> corners, ids, rejectedImgPoints
Link to this function

drawCharucoDiamond(dictionary, ids, squareLength, markerLength)

View Source
@spec drawCharucoDiamond(
  Evision.ArUco.Dictionary.t(),
  Evision.ArUco.Vec4i.t(),
  integer(),
  integer()
) ::
  Evision.Mat.t() | {:error, String.t()}

Draw a ChArUco Diamond marker

Positional Arguments
  • dictionary: Dictionary.

    dictionary of markers indicating the type of markers.

  • ids: Vec4i.

    list of 4 ids for each ArUco marker in the ChArUco marker.

  • squareLength: int.

    size of the chessboard squares in pixels.

  • markerLength: int.

    size of the markers in pixels.

Keyword Arguments
  • marginSize: int.

    minimum margins (in pixels) of the marker in the output image

  • borderBits: int.

    width of the marker borders.

Return
  • img: Evision.Mat.t().

    output image with the marker. The size of this image will be 3squareLength + 2marginSize,.

This function return the image of a ChArUco marker, ready to be printed.

Python prototype (for reference only):

drawCharucoDiamond(dictionary, ids, squareLength, markerLength[, img[, marginSize[, borderBits]]]) -> img
Link to this function

drawCharucoDiamond(dictionary, ids, squareLength, markerLength, opts)

View Source
@spec drawCharucoDiamond(
  Evision.ArUco.Dictionary.t(),
  Evision.ArUco.Vec4i.t(),
  integer(),
  integer(),
  [{atom(), term()}, ...] | nil
) :: Evision.Mat.t() | {:error, String.t()}

Draw a ChArUco Diamond marker

Positional Arguments
  • dictionary: Dictionary.

    dictionary of markers indicating the type of markers.

  • ids: Vec4i.

    list of 4 ids for each ArUco marker in the ChArUco marker.

  • squareLength: int.

    size of the chessboard squares in pixels.

  • markerLength: int.

    size of the markers in pixels.

Keyword Arguments
  • marginSize: int.

    minimum margins (in pixels) of the marker in the output image

  • borderBits: int.

    width of the marker borders.

Return
  • img: Evision.Mat.t().

    output image with the marker. The size of this image will be 3squareLength + 2marginSize,.

This function return the image of a ChArUco marker, ready to be printed.

Python prototype (for reference only):

drawCharucoDiamond(dictionary, ids, squareLength, markerLength[, img[, marginSize[, borderBits]]]) -> img
Link to this function

drawDetectedCornersCharuco(image, charucoCorners)

View Source
@spec drawDetectedCornersCharuco(
  Evision.Mat.maybe_mat_in(),
  Evision.Mat.maybe_mat_in()
) ::
  Evision.Mat.t() | {:error, String.t()}

Draws a set of Charuco corners

Positional Arguments
  • charucoCorners: Evision.Mat.t().

    vector of detected charuco corners

Keyword Arguments
  • charucoIds: Evision.Mat.t().

    list of identifiers for each corner in charucoCorners

  • cornerColor: Scalar.

    color of the square surrounding each corner

Return
  • image: Evision.Mat.t().

    input/output image. It must have 1 or 3 channels. The number of channels is not altered.

This function draws a set of detected Charuco corners. If identifiers vector is provided, it also draws the id of each corner.

Python prototype (for reference only):

drawDetectedCornersCharuco(image, charucoCorners[, charucoIds[, cornerColor]]) -> image
Link to this function

drawDetectedCornersCharuco(image, charucoCorners, opts)

View Source
@spec drawDetectedCornersCharuco(
  Evision.Mat.maybe_mat_in(),
  Evision.Mat.maybe_mat_in(),
  [{atom(), term()}, ...] | nil
) :: Evision.Mat.t() | {:error, String.t()}

Draws a set of Charuco corners

Positional Arguments
  • charucoCorners: Evision.Mat.t().

    vector of detected charuco corners

Keyword Arguments
  • charucoIds: Evision.Mat.t().

    list of identifiers for each corner in charucoCorners

  • cornerColor: Scalar.

    color of the square surrounding each corner

Return
  • image: Evision.Mat.t().

    input/output image. It must have 1 or 3 channels. The number of channels is not altered.

This function draws a set of detected Charuco corners. If identifiers vector is provided, it also draws the id of each corner.

Python prototype (for reference only):

drawDetectedCornersCharuco(image, charucoCorners[, charucoIds[, cornerColor]]) -> image
Link to this function

drawDetectedDiamonds(image, diamondCorners)

View Source
@spec drawDetectedDiamonds(Evision.Mat.maybe_mat_in(), [Evision.Mat.maybe_mat_in()]) ::
  Evision.Mat.t() | {:error, String.t()}

Draw a set of detected ChArUco Diamond markers

Positional Arguments
  • diamondCorners: [Evision.Mat].

    positions of diamond corners in the same format returned by detectCharucoDiamond(). (e.g std::vector<std::vector<cv::Point2f> > ). For N detected markers, the dimensions of this array should be Nx4. The order of the corners should be clockwise.

Keyword Arguments
  • diamondIds: Evision.Mat.t().

    vector of identifiers for diamonds in diamondCorners, in the same format returned by detectCharucoDiamond() (e.g. std::vector<Vec4i>). Optional, if not provided, ids are not painted.

  • borderColor: Scalar.

    color of marker borders. Rest of colors (text color and first corner color) are calculated based on this one.

Return
  • image: Evision.Mat.t().

    input/output image. It must have 1 or 3 channels. The number of channels is not altered.

Given an array of detected diamonds, this functions draws them in the image. The marker borders are painted and the markers identifiers if provided. Useful for debugging purposes.

Python prototype (for reference only):

drawDetectedDiamonds(image, diamondCorners[, diamondIds[, borderColor]]) -> image
Link to this function

drawDetectedDiamonds(image, diamondCorners, opts)

View Source
@spec drawDetectedDiamonds(
  Evision.Mat.maybe_mat_in(),
  [Evision.Mat.maybe_mat_in()],
  [{atom(), term()}, ...] | nil
) :: Evision.Mat.t() | {:error, String.t()}

Draw a set of detected ChArUco Diamond markers

Positional Arguments
  • diamondCorners: [Evision.Mat].

    positions of diamond corners in the same format returned by detectCharucoDiamond(). (e.g std::vector<std::vector<cv::Point2f> > ). For N detected markers, the dimensions of this array should be Nx4. The order of the corners should be clockwise.

Keyword Arguments
  • diamondIds: Evision.Mat.t().

    vector of identifiers for diamonds in diamondCorners, in the same format returned by detectCharucoDiamond() (e.g. std::vector<Vec4i>). Optional, if not provided, ids are not painted.

  • borderColor: Scalar.

    color of marker borders. Rest of colors (text color and first corner color) are calculated based on this one.

Return
  • image: Evision.Mat.t().

    input/output image. It must have 1 or 3 channels. The number of channels is not altered.

Given an array of detected diamonds, this functions draws them in the image. The marker borders are painted and the markers identifiers if provided. Useful for debugging purposes.

Python prototype (for reference only):

drawDetectedDiamonds(image, diamondCorners[, diamondIds[, borderColor]]) -> image
Link to this function

drawDetectedMarkers(image, corners)

View Source
@spec drawDetectedMarkers(Evision.Mat.maybe_mat_in(), [Evision.Mat.maybe_mat_in()]) ::
  Evision.Mat.t() | {:error, String.t()}

Draw detected markers in image

Positional Arguments
  • corners: [Evision.Mat].

    positions of marker corners on input image. (e.g std::vector<std::vector<cv::Point2f> > ). For N detected markers, the dimensions of this array should be Nx4. The order of the corners should be clockwise.

Keyword Arguments
  • ids: Evision.Mat.t().

    vector of identifiers for markers in markersCorners . Optional, if not provided, ids are not painted.

  • borderColor: Scalar.

    color of marker borders. Rest of colors (text color and first corner color) are calculated based on this one to improve visualization.

Return
  • image: Evision.Mat.t().

    input/output image. It must have 1 or 3 channels. The number of channels is not altered.

Given an array of detected marker corners and its corresponding ids, this functions draws the markers in the image. The marker borders are painted and the markers identifiers if provided. Useful for debugging purposes.

Python prototype (for reference only):

drawDetectedMarkers(image, corners[, ids[, borderColor]]) -> image
Link to this function

drawDetectedMarkers(image, corners, opts)

View Source
@spec drawDetectedMarkers(
  Evision.Mat.maybe_mat_in(),
  [Evision.Mat.maybe_mat_in()],
  [{atom(), term()}, ...] | nil
) :: Evision.Mat.t() | {:error, String.t()}

Draw detected markers in image

Positional Arguments
  • corners: [Evision.Mat].

    positions of marker corners on input image. (e.g std::vector<std::vector<cv::Point2f> > ). For N detected markers, the dimensions of this array should be Nx4. The order of the corners should be clockwise.

Keyword Arguments
  • ids: Evision.Mat.t().

    vector of identifiers for markers in markersCorners . Optional, if not provided, ids are not painted.

  • borderColor: Scalar.

    color of marker borders. Rest of colors (text color and first corner color) are calculated based on this one to improve visualization.

Return
  • image: Evision.Mat.t().

    input/output image. It must have 1 or 3 channels. The number of channels is not altered.

Given an array of detected marker corners and its corresponding ids, this functions draws the markers in the image. The marker borders are painted and the markers identifiers if provided. Useful for debugging purposes.

Python prototype (for reference only):

drawDetectedMarkers(image, corners[, ids[, borderColor]]) -> image
Link to this function

drawPlanarBoard(board, outSize, marginSize, borderBits)

View Source
@spec drawPlanarBoard(
  Evision.ArUco.Board.t(),
  {number(), number()},
  integer(),
  integer()
) ::
  Evision.Mat.t() | {:error, String.t()}

draw planar board

Positional Arguments
  • board: Board
  • outSize: Size
  • marginSize: int
  • borderBits: int
Return
  • img: Evision.Mat.t().

@deprecated Use Board::generateImage

Python prototype (for reference only):

drawPlanarBoard(board, outSize, marginSize, borderBits[, img]) -> img
Link to this function

drawPlanarBoard(board, outSize, marginSize, borderBits, opts)

View Source
@spec drawPlanarBoard(
  Evision.ArUco.Board.t(),
  {number(), number()},
  integer(),
  integer(),
  [{atom(), term()}, ...] | nil
) :: Evision.Mat.t() | {:error, String.t()}

draw planar board

Positional Arguments
  • board: Board
  • outSize: Size
  • marginSize: int
  • borderBits: int
Return
  • img: Evision.Mat.t().

@deprecated Use Board::generateImage

Python prototype (for reference only):

drawPlanarBoard(board, outSize, marginSize, borderBits[, img]) -> img
Link to this function

estimatePoseBoard(corners, ids, board, cameraMatrix, distCoeffs, rvec, tvec)

View Source

estimatePoseBoard

Positional Arguments
  • corners: [Evision.Mat]
  • ids: Evision.Mat.t()
  • board: Board
  • cameraMatrix: Evision.Mat.t()
  • distCoeffs: Evision.Mat.t()
Keyword Arguments
  • useExtrinsicGuess: bool.
Return
  • retval: int
  • rvec: Evision.Mat.t()
  • tvec: Evision.Mat.t()

@deprecated Use cv::solvePnP

Python prototype (for reference only):

estimatePoseBoard(corners, ids, board, cameraMatrix, distCoeffs, rvec, tvec[, useExtrinsicGuess]) -> retval, rvec, tvec
Link to this function

estimatePoseBoard(corners, ids, board, cameraMatrix, distCoeffs, rvec, tvec, opts)

View Source

estimatePoseBoard

Positional Arguments
  • corners: [Evision.Mat]
  • ids: Evision.Mat.t()
  • board: Board
  • cameraMatrix: Evision.Mat.t()
  • distCoeffs: Evision.Mat.t()
Keyword Arguments
  • useExtrinsicGuess: bool.
Return
  • retval: int
  • rvec: Evision.Mat.t()
  • tvec: Evision.Mat.t()

@deprecated Use cv::solvePnP

Python prototype (for reference only):

estimatePoseBoard(corners, ids, board, cameraMatrix, distCoeffs, rvec, tvec[, useExtrinsicGuess]) -> retval, rvec, tvec
Link to this function

estimatePoseCharucoBoard(charucoCorners, charucoIds, board, cameraMatrix, distCoeffs, rvec, tvec)

View Source

Pose estimation for a ChArUco board given some of their corners

Positional Arguments
  • charucoCorners: Evision.Mat.t().

    vector of detected charuco corners

  • charucoIds: Evision.Mat.t().

    list of identifiers for each corner in charucoCorners

  • board: Evision.ArUco.CharucoBoard.t().

    layout of ChArUco board.

  • cameraMatrix: Evision.Mat.t().

    input 3x3 floating-point camera matrix \f$A = \vecthreethree{f_x}{0}{c_x}{0}{f_y}{c_y}{0}{0}{1}\f$

  • distCoeffs: Evision.Mat.t().

    vector of distortion coefficients \f$(k_1, k_2, p_1, p_2[, k_3[, k_4, k_5, k_6],[s_1, s_2, s_3, s_4]])\f$ of 4, 5, 8 or 12 elements

Keyword Arguments
  • useExtrinsicGuess: bool.

    defines whether initial guess for \b rvec and \b tvec will be used or not.

Return
  • retval: bool

  • rvec: Evision.Mat.t().

    Output vector (e.g. cv::Mat) corresponding to the rotation vector of the board (see cv::Rodrigues).

  • tvec: Evision.Mat.t().

    Output vector (e.g. cv::Mat) corresponding to the translation vector of the board.

This function estimates a Charuco board pose from some detected corners. The function checks if the input corners are enough and valid to perform pose estimation. If pose estimation is valid, returns true, else returns false. @sa use cv::drawFrameAxes to get world coordinate system axis for object points

Python prototype (for reference only):

estimatePoseCharucoBoard(charucoCorners, charucoIds, board, cameraMatrix, distCoeffs, rvec, tvec[, useExtrinsicGuess]) -> retval, rvec, tvec
Link to this function

estimatePoseCharucoBoard(charucoCorners, charucoIds, board, cameraMatrix, distCoeffs, rvec, tvec, opts)

View Source

Pose estimation for a ChArUco board given some of their corners

Positional Arguments
  • charucoCorners: Evision.Mat.t().

    vector of detected charuco corners

  • charucoIds: Evision.Mat.t().

    list of identifiers for each corner in charucoCorners

  • board: Evision.ArUco.CharucoBoard.t().

    layout of ChArUco board.

  • cameraMatrix: Evision.Mat.t().

    input 3x3 floating-point camera matrix \f$A = \vecthreethree{f_x}{0}{c_x}{0}{f_y}{c_y}{0}{0}{1}\f$

  • distCoeffs: Evision.Mat.t().

    vector of distortion coefficients \f$(k_1, k_2, p_1, p_2[, k_3[, k_4, k_5, k_6],[s_1, s_2, s_3, s_4]])\f$ of 4, 5, 8 or 12 elements

Keyword Arguments
  • useExtrinsicGuess: bool.

    defines whether initial guess for \b rvec and \b tvec will be used or not.

Return
  • retval: bool

  • rvec: Evision.Mat.t().

    Output vector (e.g. cv::Mat) corresponding to the rotation vector of the board (see cv::Rodrigues).

  • tvec: Evision.Mat.t().

    Output vector (e.g. cv::Mat) corresponding to the translation vector of the board.

This function estimates a Charuco board pose from some detected corners. The function checks if the input corners are enough and valid to perform pose estimation. If pose estimation is valid, returns true, else returns false. @sa use cv::drawFrameAxes to get world coordinate system axis for object points

Python prototype (for reference only):

estimatePoseCharucoBoard(charucoCorners, charucoIds, board, cameraMatrix, distCoeffs, rvec, tvec[, useExtrinsicGuess]) -> retval, rvec, tvec
Link to this function

estimatePoseSingleMarkers(corners, markerLength, cameraMatrix, distCoeffs)

View Source
@spec estimatePoseSingleMarkers(
  [Evision.Mat.maybe_mat_in()],
  number(),
  Evision.Mat.maybe_mat_in(),
  Evision.Mat.maybe_mat_in()
) :: {Evision.Mat.t(), Evision.Mat.t(), Evision.Mat.t()} | {:error, String.t()}

estimatePoseSingleMarkers

Positional Arguments
  • corners: [Evision.Mat]
  • markerLength: float
  • cameraMatrix: Evision.Mat.t()
  • distCoeffs: Evision.Mat.t()
Keyword Arguments
  • estimateParameters: EstimateParameters.
Return
  • rvecs: Evision.Mat.t().
  • tvecs: Evision.Mat.t().
  • objPoints: Evision.Mat.t().

@deprecated Use cv::solvePnP

Python prototype (for reference only):

estimatePoseSingleMarkers(corners, markerLength, cameraMatrix, distCoeffs[, rvecs[, tvecs[, objPoints[, estimateParameters]]]]) -> rvecs, tvecs, objPoints
Link to this function

estimatePoseSingleMarkers(corners, markerLength, cameraMatrix, distCoeffs, opts)

View Source
@spec estimatePoseSingleMarkers(
  [Evision.Mat.maybe_mat_in()],
  number(),
  Evision.Mat.maybe_mat_in(),
  Evision.Mat.maybe_mat_in(),
  [{atom(), term()}, ...] | nil
) :: {Evision.Mat.t(), Evision.Mat.t(), Evision.Mat.t()} | {:error, String.t()}

estimatePoseSingleMarkers

Positional Arguments
  • corners: [Evision.Mat]
  • markerLength: float
  • cameraMatrix: Evision.Mat.t()
  • distCoeffs: Evision.Mat.t()
Keyword Arguments
  • estimateParameters: EstimateParameters.
Return
  • rvecs: Evision.Mat.t().
  • tvecs: Evision.Mat.t().
  • objPoints: Evision.Mat.t().

@deprecated Use cv::solvePnP

Python prototype (for reference only):

estimatePoseSingleMarkers(corners, markerLength, cameraMatrix, distCoeffs[, rvecs[, tvecs[, objPoints[, estimateParameters]]]]) -> rvecs, tvecs, objPoints
Link to this function

extendDictionary(nMarkers, markerSize)

View Source
@spec extendDictionary(integer(), integer()) ::
  Evision.ArUco.Dictionary.t() | {:error, String.t()}

Extend base dictionary by new nMarkers

Positional Arguments
  • nMarkers: int.

    number of markers in the dictionary

  • markerSize: int.

    number of bits per dimension of each markers

Keyword Arguments
  • baseDictionary: Dictionary.

    Include the markers in this dictionary at the beginning (optional)

  • randomSeed: int.

    a user supplied seed for theRNG()

Return
  • retval: Dictionary

This function creates a new dictionary composed by nMarkers markers and each markers composed by markerSize x markerSize bits. If baseDictionary is provided, its markers are directly included and the rest are generated based on them. If the size of baseDictionary is higher than nMarkers, only the first nMarkers in baseDictionary are taken and no new marker is added.

Python prototype (for reference only):

extendDictionary(nMarkers, markerSize[, baseDictionary[, randomSeed]]) -> retval
Link to this function

extendDictionary(nMarkers, markerSize, opts)

View Source
@spec extendDictionary(integer(), integer(), [{atom(), term()}, ...] | nil) ::
  Evision.ArUco.Dictionary.t() | {:error, String.t()}

Extend base dictionary by new nMarkers

Positional Arguments
  • nMarkers: int.

    number of markers in the dictionary

  • markerSize: int.

    number of bits per dimension of each markers

Keyword Arguments
  • baseDictionary: Dictionary.

    Include the markers in this dictionary at the beginning (optional)

  • randomSeed: int.

    a user supplied seed for theRNG()

Return
  • retval: Dictionary

This function creates a new dictionary composed by nMarkers markers and each markers composed by markerSize x markerSize bits. If baseDictionary is provided, its markers are directly included and the rest are generated based on them. If the size of baseDictionary is higher than nMarkers, only the first nMarkers in baseDictionary are taken and no new marker is added.

Python prototype (for reference only):

extendDictionary(nMarkers, markerSize[, baseDictionary[, randomSeed]]) -> retval
Link to this function

generateImageMarker(dictionary, id, sidePixels)

View Source
@spec generateImageMarker(Evision.ArUco.Dictionary.t(), integer(), integer()) ::
  Evision.Mat.t() | {:error, String.t()}

Generate a canonical marker image

Positional Arguments
  • dictionary: Dictionary.

    dictionary of markers indicating the type of markers

  • id: int.

    identifier of the marker that will be returned. It has to be a valid id in the specified dictionary.

  • sidePixels: int.

    size of the image in pixels

Keyword Arguments
  • borderBits: int.

    width of the marker border.

Return
  • img: Evision.Mat.t().

    output image with the marker

This function returns a marker image in its canonical form (i.e. ready to be printed)

Python prototype (for reference only):

generateImageMarker(dictionary, id, sidePixels[, img[, borderBits]]) -> img
Link to this function

generateImageMarker(dictionary, id, sidePixels, opts)

View Source
@spec generateImageMarker(
  Evision.ArUco.Dictionary.t(),
  integer(),
  integer(),
  [{atom(), term()}, ...] | nil
) :: Evision.Mat.t() | {:error, String.t()}

Generate a canonical marker image

Positional Arguments
  • dictionary: Dictionary.

    dictionary of markers indicating the type of markers

  • id: int.

    identifier of the marker that will be returned. It has to be a valid id in the specified dictionary.

  • sidePixels: int.

    size of the image in pixels

Keyword Arguments
  • borderBits: int.

    width of the marker border.

Return
  • img: Evision.Mat.t().

    output image with the marker

This function returns a marker image in its canonical form (i.e. ready to be printed)

Python prototype (for reference only):

generateImageMarker(dictionary, id, sidePixels[, img[, borderBits]]) -> img
Link to this function

getBoardObjectAndImagePoints(board, detectedCorners, detectedIds)

View Source
@spec getBoardObjectAndImagePoints(
  Evision.ArUco.Board.t(),
  [Evision.Mat.maybe_mat_in()],
  Evision.Mat.maybe_mat_in()
) :: {Evision.Mat.t(), Evision.Mat.t()} | {:error, String.t()}

get board object and image points

Positional Arguments
  • board: Board
  • detectedCorners: [Evision.Mat]
  • detectedIds: Evision.Mat.t()
Return
  • objPoints: Evision.Mat.t().
  • imgPoints: Evision.Mat.t().

@deprecated Use Board::matchImagePoints

Python prototype (for reference only):

getBoardObjectAndImagePoints(board, detectedCorners, detectedIds[, objPoints[, imgPoints]]) -> objPoints, imgPoints
Link to this function

getBoardObjectAndImagePoints(board, detectedCorners, detectedIds, opts)

View Source
@spec getBoardObjectAndImagePoints(
  Evision.ArUco.Board.t(),
  [Evision.Mat.maybe_mat_in()],
  Evision.Mat.maybe_mat_in(),
  [{atom(), term()}, ...] | nil
) :: {Evision.Mat.t(), Evision.Mat.t()} | {:error, String.t()}

get board object and image points

Positional Arguments
  • board: Board
  • detectedCorners: [Evision.Mat]
  • detectedIds: Evision.Mat.t()
Return
  • objPoints: Evision.Mat.t().
  • imgPoints: Evision.Mat.t().

@deprecated Use Board::matchImagePoints

Python prototype (for reference only):

getBoardObjectAndImagePoints(board, detectedCorners, detectedIds[, objPoints[, imgPoints]]) -> objPoints, imgPoints
Link to this function

getPredefinedDictionary(dict)

View Source
@spec getPredefinedDictionary(integer()) ::
  Evision.ArUco.Dictionary.t() | {:error, String.t()}

Returns one of the predefined dictionaries referenced by DICT_*.

Positional Arguments
  • dict: int
Return
  • retval: Dictionary

Python prototype (for reference only):

getPredefinedDictionary(dict) -> retval
Link to this function

interpolateCornersCharuco(markerCorners, markerIds, image, board)

View Source

Interpolate position of ChArUco board corners

Positional Arguments
  • markerCorners: [Evision.Mat].

    vector of already detected markers corners. For each marker, its four corners are provided, (e.g std::vector<std::vector<cv::Point2f> > ). For N detected markers, the dimensions of this array should be Nx4. The order of the corners should be clockwise.

  • markerIds: Evision.Mat.t().

    list of identifiers for each marker in corners

  • image: Evision.Mat.t().

    input image necesary for corner refinement. Note that markers are not detected and should be sent in corners and ids parameters.

  • board: Evision.ArUco.CharucoBoard.t().

    layout of ChArUco board.

Keyword Arguments
  • cameraMatrix: Evision.Mat.t().

    optional 3x3 floating-point camera matrix \f$A = \vecthreethree{f_x}{0}{c_x}{0}{f_y}{c_y}{0}{0}{1}\f$

  • distCoeffs: Evision.Mat.t().

    optional vector of distortion coefficients \f$(k_1, k_2, p_1, p_2[, k_3[, k_4, k_5, k_6],[s_1, s_2, s_3, s_4]])\f$ of 4, 5, 8 or 12 elements

  • minMarkers: int.

    number of adjacent markers that must be detected to return a charuco corner

Return
  • retval: int

  • charucoCorners: Evision.Mat.t().

    interpolated chessboard corners

  • charucoIds: Evision.Mat.t().

    interpolated chessboard corners identifiers

This function receives the detected markers and returns the 2D position of the chessboard corners from a ChArUco board using the detected Aruco markers. If camera parameters are provided, the process is based in an approximated pose estimation, else it is based on local homography. Only visible corners are returned. For each corner, its corresponding identifier is also returned in charucoIds. The function returns the number of interpolated corners. @deprecated Use CharucoDetector::detectBoard

Python prototype (for reference only):

interpolateCornersCharuco(markerCorners, markerIds, image, board[, charucoCorners[, charucoIds[, cameraMatrix[, distCoeffs[, minMarkers]]]]]) -> retval, charucoCorners, charucoIds
Link to this function

interpolateCornersCharuco(markerCorners, markerIds, image, board, opts)

View Source
@spec interpolateCornersCharuco(
  [Evision.Mat.maybe_mat_in()],
  Evision.Mat.maybe_mat_in(),
  Evision.Mat.maybe_mat_in(),
  Evision.ArUco.CharucoBoard.t(),
  [{atom(), term()}, ...] | nil
) :: {integer(), Evision.Mat.t(), Evision.Mat.t()} | {:error, String.t()}

Interpolate position of ChArUco board corners

Positional Arguments
  • markerCorners: [Evision.Mat].

    vector of already detected markers corners. For each marker, its four corners are provided, (e.g std::vector<std::vector<cv::Point2f> > ). For N detected markers, the dimensions of this array should be Nx4. The order of the corners should be clockwise.

  • markerIds: Evision.Mat.t().

    list of identifiers for each marker in corners

  • image: Evision.Mat.t().

    input image necesary for corner refinement. Note that markers are not detected and should be sent in corners and ids parameters.

  • board: Evision.ArUco.CharucoBoard.t().

    layout of ChArUco board.

Keyword Arguments
  • cameraMatrix: Evision.Mat.t().

    optional 3x3 floating-point camera matrix \f$A = \vecthreethree{f_x}{0}{c_x}{0}{f_y}{c_y}{0}{0}{1}\f$

  • distCoeffs: Evision.Mat.t().

    optional vector of distortion coefficients \f$(k_1, k_2, p_1, p_2[, k_3[, k_4, k_5, k_6],[s_1, s_2, s_3, s_4]])\f$ of 4, 5, 8 or 12 elements

  • minMarkers: int.

    number of adjacent markers that must be detected to return a charuco corner

Return
  • retval: int

  • charucoCorners: Evision.Mat.t().

    interpolated chessboard corners

  • charucoIds: Evision.Mat.t().

    interpolated chessboard corners identifiers

This function receives the detected markers and returns the 2D position of the chessboard corners from a ChArUco board using the detected Aruco markers. If camera parameters are provided, the process is based in an approximated pose estimation, else it is based on local homography. Only visible corners are returned. For each corner, its corresponding identifier is also returned in charucoIds. The function returns the number of interpolated corners. @deprecated Use CharucoDetector::detectBoard

Python prototype (for reference only):

interpolateCornersCharuco(markerCorners, markerIds, image, board[, charucoCorners[, charucoIds[, cameraMatrix[, distCoeffs[, minMarkers]]]]]) -> retval, charucoCorners, charucoIds
Link to this function

refineDetectedMarkers(image, board, detectedCorners, detectedIds, rejectedCorners)

View Source

refine detected markers

Positional Arguments
  • image: Evision.Mat.t()
  • board: Board
Keyword Arguments
  • cameraMatrix: Evision.Mat.t().
  • distCoeffs: Evision.Mat.t().
  • minRepDistance: float.
  • errorCorrectionRate: float.
  • checkAllOrders: bool.
  • parameters: DetectorParameters.
Return
  • detectedCorners: [Evision.Mat]
  • detectedIds: Evision.Mat.t()
  • rejectedCorners: [Evision.Mat]
  • recoveredIdxs: Evision.Mat.t().

@deprecated Use class ArucoDetector::refineDetectedMarkers

Python prototype (for reference only):

refineDetectedMarkers(image, board, detectedCorners, detectedIds, rejectedCorners[, cameraMatrix[, distCoeffs[, minRepDistance[, errorCorrectionRate[, checkAllOrders[, recoveredIdxs[, parameters]]]]]]]) -> detectedCorners, detectedIds, rejectedCorners, recoveredIdxs
Link to this function

refineDetectedMarkers(image, board, detectedCorners, detectedIds, rejectedCorners, opts)

View Source

refine detected markers

Positional Arguments
  • image: Evision.Mat.t()
  • board: Board
Keyword Arguments
  • cameraMatrix: Evision.Mat.t().
  • distCoeffs: Evision.Mat.t().
  • minRepDistance: float.
  • errorCorrectionRate: float.
  • checkAllOrders: bool.
  • parameters: DetectorParameters.
Return
  • detectedCorners: [Evision.Mat]
  • detectedIds: Evision.Mat.t()
  • rejectedCorners: [Evision.Mat]
  • recoveredIdxs: Evision.Mat.t().

@deprecated Use class ArucoDetector::refineDetectedMarkers

Python prototype (for reference only):

refineDetectedMarkers(image, board, detectedCorners, detectedIds, rejectedCorners[, cameraMatrix[, distCoeffs[, minRepDistance[, errorCorrectionRate[, checkAllOrders[, recoveredIdxs[, parameters]]]]]]]) -> detectedCorners, detectedIds, rejectedCorners, recoveredIdxs
Link to this function

testCharucoCornersCollinear(board, charucoIds)

View Source
@spec testCharucoCornersCollinear(
  Evision.ArUco.CharucoBoard.t(),
  Evision.Mat.maybe_mat_in()
) ::
  boolean() | {:error, String.t()}

testCharucoCornersCollinear

Positional Arguments
  • board: Evision.ArUco.CharucoBoard.t()
  • charucoIds: Evision.Mat.t()
Return
  • retval: bool

@deprecated Use CharucoBoard::checkCharucoCornersCollinear

Python prototype (for reference only):

testCharucoCornersCollinear(board, charucoIds) -> retval