Mech-Eye API 2.4.0
API reference documentation for Mech-Eye Industrial 3D Camera
Loading...
Searching...
No Matches
HandEyeCalibration.h
1#pragma once
2#include <cmath>
3#include "Camera.h"
4#include "CameraProperties.h"
5
6namespace mmind {
7
8namespace eye {
9
10class MMIND_API_EXPORT HandEyeCalibration
11{
12public:
17 enum struct CameraMountingMode {
18 EyeInHand,
19 EyeToHand,
20 };
21
26 BDB_5,
27 BDB_6,
28 BDB_7,
29 OCB_5,
30 OCB_10,
31 OCB_15,
32 OCB_20,
33 CGB_20,
34 CGB_35,
35 CGB_50,
36 };
37
43 {
44 Transformation() = default;
45 Transformation(double x, double y, double z, double qW, double qX, double qY, double qZ)
46 : x(x), y(y), z(z), qW(qW), qX(qX), qY(qY), qZ(qZ)
47 {
48 }
49
50 std::string toString() const
51 {
52 char buff[256] = {0};
53 snprintf(buff, sizeof(buff), "%lf,%lf,%lf,%lf,%lf,%lf,%lf", x, y, z, qW, qX, qY, qZ);
54 return buff;
55 }
56 double x{}; // Translation 3*1 vector robot pose unit: mm; extrinsic unit: m.
57 double y{};
58 double z{};
59 double qW{1}; // Quaternion 4*1 vector
60 double qX{};
61 double qY{};
62 double qZ{};
63 };
74
88 Color2DImage& color2DImage, unsigned int timeoutMs = 10000);
89
97
109 unsigned int timeoutMs = 10000);
110};
111
112} // namespace eye
113
114} // namespace mmind
Represents a 2D container of data.
Definition Array2D.h:17
Operates the camera. Use Camera::connect to connect an available camera, and then call the correspond...
Definition Camera.h:55
ErrorStatus initializeCalibration(Camera &camera, CameraMountingMode mountingMode, CalibrationBoardModel boardModel)
Sets the board model and camera mounting mode for this calibration.
ErrorStatus addPoseAndDetect(Camera &camera, const Transformation &poseData, Color2DImage &color2DImage, unsigned int timeoutMs=10000)
Adds current pose of the robot, captures the image, and calculates necessary parameters prepared for ...
ErrorStatus calculateExtrinsics(Camera &camera, Transformation &cameraToBase)
Starts to calculate the result of hand-eye calibration.
ErrorStatus testRecognition(Camera &camera, Color2DImage &testResult, unsigned int timeoutMs=10000)
Only captures current image with feature recognition result for test.
Describes the types of errors.
Definition ErrorStatus.h:12
Defines rigid body transformations, including translation vector and quaternion vector.