View Source Evision.ArUco.CharucoBoard (Evision v0.1.38)

Summary

Types

t()

Type that represents an ArUco.CharucoBoard struct.

Functions

check whether the ChArUco markers are collinear

get CharucoBoard::chessboardCorners

getChessboardSize

getLegacyPattern

getMarkerLength

getSquareLength

set legacy chessboard pattern.

Types

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

Type that represents an ArUco.CharucoBoard struct.

  • ref. reference()

    The underlying erlang resource variable.

Functions

Link to this function

charucoBoard(size, squareLength, markerLength, dictionary)

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

CharucoBoard constructor

Positional Arguments
  • size: Size.

    number of chessboard squares in x and y directions

  • squareLength: float.

    squareLength chessboard square side length (normally in meters)

  • markerLength: float.

    marker side length (same unit than squareLength)

  • dictionary: Dictionary.

    dictionary of markers indicating the type of markers

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

    array of id used markers The first markers in the dictionary are used to fill the white chessboard squares.

Return
  • self: Evision.ArUco.CharucoBoard.t()

Python prototype (for reference only):

CharucoBoard(size, squareLength, markerLength, dictionary[, ids]) -> <aruco_CharucoBoard object>
Link to this function

charucoBoard(size, squareLength, markerLength, dictionary, opts)

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

CharucoBoard constructor

Positional Arguments
  • size: Size.

    number of chessboard squares in x and y directions

  • squareLength: float.

    squareLength chessboard square side length (normally in meters)

  • markerLength: float.

    marker side length (same unit than squareLength)

  • dictionary: Dictionary.

    dictionary of markers indicating the type of markers

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

    array of id used markers The first markers in the dictionary are used to fill the white chessboard squares.

Return
  • self: Evision.ArUco.CharucoBoard.t()

Python prototype (for reference only):

CharucoBoard(size, squareLength, markerLength, dictionary[, ids]) -> <aruco_CharucoBoard object>
Link to this function

checkCharucoCornersCollinear(self, charucoIds)

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

check whether the ChArUco markers are collinear

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

  • charucoIds: Evision.Mat.t().

    list of identifiers for each corner in charucoCorners per frame.

Return
  • retval: bool

@return bool value, 1 (true) if detected corners form a line, 0 (false) if they do not. solvePnP, calibration functions will fail if the corners are collinear (true). The number of ids in charucoIDs should be <= the number of chessboard corners in the board. This functions checks whether the charuco corners are on a straight line (returns true, if so), or not (false). Axis parallel, as well as diagonal and other straight lines detected. Degenerate cases: for number of charucoIDs <= 2,the function returns true.

Python prototype (for reference only):

checkCharucoCornersCollinear(charucoIds) -> retval
Link to this function

getChessboardCorners(self)

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

get CharucoBoard::chessboardCorners

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

Python prototype (for reference only):

getChessboardCorners() -> retval
@spec getChessboardSize(t()) :: {number(), number()} | {:error, String.t()}

getChessboardSize

Positional Arguments
  • self: Evision.ArUco.CharucoBoard.t()
Return
  • retval: Size

Python prototype (for reference only):

getChessboardSize() -> retval
@spec getLegacyPattern(t()) :: boolean() | {:error, String.t()}

getLegacyPattern

Positional Arguments
  • self: Evision.ArUco.CharucoBoard.t()
Return
  • retval: bool

Python prototype (for reference only):

getLegacyPattern() -> retval
@spec getMarkerLength(t()) :: number() | {:error, String.t()}

getMarkerLength

Positional Arguments
  • self: Evision.ArUco.CharucoBoard.t()
Return
  • retval: float

Python prototype (for reference only):

getMarkerLength() -> retval
@spec getSquareLength(t()) :: number() | {:error, String.t()}

getSquareLength

Positional Arguments
  • self: Evision.ArUco.CharucoBoard.t()
Return
  • retval: float

Python prototype (for reference only):

getSquareLength() -> retval
Link to this function

setLegacyPattern(self, legacyPattern)

View Source
@spec setLegacyPattern(t(), boolean()) :: t() | {:error, String.t()}

set legacy chessboard pattern.

Positional Arguments
  • self: Evision.ArUco.CharucoBoard.t()
  • legacyPattern: bool

Legacy setting creates chessboard patterns starting with a white box in the upper left corner if there is an even row count of chessboard boxes, otherwise it starts with a black box. This setting ensures compatibility to patterns created with OpenCV versions prior OpenCV 4.6.0. See https://github.com/opencv/opencv/issues/23152. Default value: false.

Python prototype (for reference only):

setLegacyPattern(legacyPattern) -> None