View Source Evision.ArUco.Board (Evision v0.1.28)

Link to this section Summary

Types

t()

Type that represents an ArUco.Board struct.

Functions

Common Board constructor

Draw a planar board

return the Dictionary of markers employed for this board

vector of the identifiers of the markers in the board (should be the same size as objPoints)

return array of object points of all the marker corners in the board.

get coordinate of the bottom right corner of the board, is set when calling the function create()

Given a board configuration and a set of detected markers, returns the corresponding image points and object points to call solvePnP()

Given a board configuration and a set of detected markers, returns the corresponding image points and object points to call solvePnP()

Link to this section Types

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

Type that represents an ArUco.Board struct.

  • ref. reference()

    The underlying erlang resource variable.

Link to this section Functions

Link to this function

board(objPoints, dictionary, ids)

View Source

Common Board constructor

Positional Arguments
  • objPoints: [Evision.Mat].

    array of object points of all the marker corners in the board

  • dictionary: Dictionary.

    the dictionary of markers employed for this board

  • ids: Evision.Mat.t().

    vector of the identifiers of the markers in the board

Return
  • self: Board

Python prototype (for reference only):

Board(objPoints, dictionary, ids) -> <aruco_Board object>
Link to this function

generateImage(self, outSize)

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

Draw a planar board

Positional Arguments
  • self: Evision.ArUco.Board.t()

  • outSize: Size.

    size of the output image in pixels.

Keyword Arguments
  • marginSize: int.

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

  • borderBits: int.

    width of the marker borders.

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

    output image with the board. The size of this image will be outSize and the board will be on the center, keeping the board proportions.

This function return the image of the board, ready to be printed.

Python prototype (for reference only):

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

generateImage(self, outSize, opts)

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

Draw a planar board

Positional Arguments
  • self: Evision.ArUco.Board.t()

  • outSize: Size.

    size of the output image in pixels.

Keyword Arguments
  • marginSize: int.

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

  • borderBits: int.

    width of the marker borders.

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

    output image with the board. The size of this image will be outSize and the board will be on the center, keeping the board proportions.

This function return the image of the board, ready to be printed.

Python prototype (for reference only):

generateImage(outSize[, img[, marginSize[, borderBits]]]) -> img
@spec getDictionary(t()) :: Evision.ArUco.Dictionary.t() | {:error, String.t()}

return the Dictionary of markers employed for this board

Positional Arguments
  • self: Evision.ArUco.Board.t()
Return
  • retval: Dictionary

Python prototype (for reference only):

getDictionary() -> retval
@spec getIds(t()) :: [integer()] | {:error, String.t()}

vector of the identifiers of the markers in the board (should be the same size as objPoints)

Positional Arguments
  • self: Evision.ArUco.Board.t()
Return
  • retval: [int]

@return vector of the identifiers of the markers

Python prototype (for reference only):

getIds() -> retval
@spec getObjPoints(t()) :: [[{number(), number(), number()}]] | {:error, String.t()}

return array of object points of all the marker corners in the board.

Positional Arguments
  • self: Evision.ArUco.Board.t()
Return
  • retval: [[Point3f]]

Each marker include its 4 corners in this order:

  • objPoints[i][0] - left-top point of i-th marker
  • objPoints[i][1] - right-top point of i-th marker
  • objPoints[i][2] - right-bottom point of i-th marker
  • objPoints[i][3] - left-bottom point of i-th marker

Markers are placed in a certain order - row by row, left to right in every row. For M markers, the size is Mx4.

Python prototype (for reference only):

getObjPoints() -> retval
Link to this function

getRightBottomCorner(self)

View Source
@spec getRightBottomCorner(t()) ::
  {number(), number(), number()} | {:error, String.t()}

get coordinate of the bottom right corner of the board, is set when calling the function create()

Positional Arguments
  • self: Evision.ArUco.Board.t()
Return
  • retval: Point3f

Python prototype (for reference only):

getRightBottomCorner() -> retval
Link to this function

matchImagePoints(self, detectedCorners, detectedIds)

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

Given a board configuration and a set of detected markers, returns the corresponding image points and object points to call solvePnP()

Positional Arguments
  • self: Evision.ArUco.Board.t()

  • detectedCorners: [Evision.Mat].

    List of detected marker corners of the board. For CharucoBoard class you can set list of charuco corners.

  • detectedIds: Evision.Mat.t().

    List of identifiers for each marker or list of charuco identifiers for each corner. For CharucoBoard class you can set list of charuco identifiers for each corner.

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

    Vector of vectors of board marker points in the board coordinate space.

  • imgPoints: Evision.Mat.t().

    Vector of vectors of the projections of board marker corner points.

Python prototype (for reference only):

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

matchImagePoints(self, detectedCorners, detectedIds, opts)

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

Given a board configuration and a set of detected markers, returns the corresponding image points and object points to call solvePnP()

Positional Arguments
  • self: Evision.ArUco.Board.t()

  • detectedCorners: [Evision.Mat].

    List of detected marker corners of the board. For CharucoBoard class you can set list of charuco corners.

  • detectedIds: Evision.Mat.t().

    List of identifiers for each marker or list of charuco identifiers for each corner. For CharucoBoard class you can set list of charuco identifiers for each corner.

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

    Vector of vectors of board marker points in the board coordinate space.

  • imgPoints: Evision.Mat.t().

    Vector of vectors of the projections of board marker corner points.

Python prototype (for reference only):

matchImagePoints(detectedCorners, detectedIds[, objPoints[, imgPoints]]) -> objPoints, imgPoints