Rust Wrapper Overview¶
The Rust wrapper provides access to libCalibGeom calibration functionality through an idiomatic Rust API.
A typical calibration flow in Rust follows a clear setup → detect → solve pattern.
- Validate your license first using the wrapper entry point (for example,
validate_license_with_certificate(...)orvalidate_license_with_env()). - Create the calibration session (for example
Calibration::new(...)) and keep that object alive for the full workflow. - Register your calibration graph by adding entities such as targets, cameras, and poses (for example
add_target(...),add_camera(...),add_pose(...)), plus optional lidar or robot nodes when needed. - Build detections from input data (images, point clouds, or both), then insert them into the session with APIs like
add_image_detection(...)or related detection calls. - Run solving in two phases: call
initialize(...)to get a stable starting point, then calloptimize(...)for final parameter refinement. - Inspect outputs and diagnostics by reading optimized parameters, reprojection/error statistics, and comparison results from returned result objects.
In practice, your control flow usually looks like validate -> create -> add nodes -> add detections -> initialize -> optimize -> inspect.
See the runnable walkthroughs in Single Camera Example and Stereo Calibration Example, and use Rustdoc for detailed type and method signatures.