Expand description
Checkerboard marker target detector (checkerboard + 3 circles in the middle).
Pipeline overview:
- Detect a chessboard grid from ChESS corners (partial boards are allowed).
- Score circular markers per-cell in image space.
- Match circle candidates to the known layout and estimate the grid offset.
- Return typed marker-board corners with optional board alignment.
§Quickstart
use calib_targets_marker::{
CellCoords, CirclePolarity, GrayImageView, MarkerBoardDetector, MarkerBoardSpec,
MarkerBoardParams, MarkerCircleSpec,
};
let board = MarkerBoardSpec::new(
6,
8,
[
MarkerCircleSpec::new(CellCoords { i: 2, j: 2 }, CirclePolarity::White),
MarkerCircleSpec::new(CellCoords { i: 3, j: 2 }, CirclePolarity::Black),
MarkerCircleSpec::new(CellCoords { i: 2, j: 3 }, CirclePolarity::White),
],
)
.with_cell_size(1.0);
let params = MarkerBoardParams::for_board(board);
let detector = MarkerBoardDetector::new(params).expect("valid chessboard config");
let pixels = vec![0u8; 32 * 32];
let view = GrayImageView {
width: 32,
height: 32,
data: &pixels,
};
// `detect` runs the ChESS corner front-end from `params.chess` itself.
// Feed a corner cloud you already have to `detect_with_corners` instead.
let _ = detector.detect(&view);Re-exports§
pub use diagnostics::MarkerBoardDiagnostics;
Modules§
- diagnostics
- Opt-in diagnostics surface for the marker-board detector.
Structs§
- Cell
Coords - Integer coordinates for a square cell in the grid (top-left corner indices).
- Cell
Offset - Integer translation between detected grid cells and board cells.
- Chess
Corner - Canonical 2D corner consumed by the chessboard detector.
- Circle
Candidate - One scored circular-marker candidate found in a chessboard cell.
- Circle
Match - Result of matching expected circles to detected candidates.
- Circle
Match Params - Circle matching settings.
- Circle
Score Params - Tuning knobs for per-cell circular-marker scoring.
- Gray
Image View - Borrowed view over an 8-bit grayscale image.
- Grid
Transform - An affine integer lattice-coordinate transform:
destination = matrix * source + translation. - Marker
Board Corner - A detected marker-board checkerboard corner.
- Marker
Board Detection - Marker-board detection result.
- Marker
Board Detector - Marker board detector: chessboard + three circle markers.
- Marker
Board Params - Parameters for marker-board detection.
- Marker
Board Spec - Fixed marker board layout: chessboard size plus 3 circle markers.
- Marker
Circle Spec - One expected marker circle on the board.
Enums§
- Circle
Polarity - Whether the circle marker prints as white-on-black or black-on-white.
- Marker
Board Detect Error - Errors returned by the marker-board detector.
Type Aliases§
- Grid
Alignment - Semantic alias for a transform that maps detected grid coordinates into a board/model coordinate frame.