1using System.Runtime.InteropServices;
7internal static class Types
9 internal enum peak_icv_point_type
11 PEAK_ICV_POINT_TYPE_XYZ = 0,
12 PEAK_ICV_POINT_TYPE_XYZ_I8 = 1,
13 PEAK_ICV_POINT_TYPE_XYZ_I10 = 2,
14 PEAK_ICV_POINT_TYPE_XYZ_I12 = 3,
15 PEAK_ICV_POINT_TYPE_XY = 4
18 internal enum peak_icv_status
20 PEAK_ICV_STATUS_SUCCESS = 0,
21 PEAK_ICV_STATUS_LIBRARY_NOT_INITIALIZED = 1,
22 PEAK_ICV_STATUS_DYNAMIC_DEPENDENCY_MISSING = 2,
23 PEAK_ICV_STATUS_MISMATCH = 3,
24 PEAK_ICV_STATUS_NOT_SUPPORTED = 4,
25 PEAK_ICV_STATUS_NOT_POSSIBLE = 5,
26 PEAK_ICV_STATUS_NULL_POINTER = 6,
27 PEAK_ICV_STATUS_INVALID_HANDLE = 7,
28 PEAK_ICV_STATUS_OUT_OF_RANGE = 8,
29 PEAK_ICV_STATUS_MATH_ERROR = 9,
30 PEAK_ICV_STATUS_TARGET_NOT_FOUND = 10,
31 PEAK_ICV_STATUS_CORRUPTED = 11,
32 PEAK_ICV_STATUS_IO_ERROR = 12,
33 PEAK_ICV_STATUS_INTERNAL_ERROR = 13,
34 PEAK_ICV_STATUS_INVALID_BUFFER_SIZE = 14
37 [StructLayout(LayoutKind.Sequential)]
38 internal struct peak_icv_point
43 public peak_icv_point(
int xval,
int yval)
50 [StructLayout(LayoutKind.Sequential)]
51 internal struct peak_common_point_u
56 public peak_common_point_u(uint xval, uint yval)
63 [StructLayout(LayoutKind.Sequential)]
64 internal struct peak_icv_point_f
69 public peak_icv_point_f(
float xval,
float yval)
76 public static implicit
operator PointF(peak_icv_point_f p)
78 return new PointF(p.x, p.y);
81 public static implicit
operator VectorF(peak_icv_point_f p)
87 [StructLayout(LayoutKind.Sequential)]
88 internal struct peak_common_rectangle
96 [StructLayout(LayoutKind.Sequential)]
97 internal struct peak_common_rectangle_u
106 [StructLayout(LayoutKind.Sequential)]
107 internal struct peak_common_size
113 [StructLayout(LayoutKind.Sequential)]
114 internal struct peak_icv_image_info
117 public peak_common_size size;
118 public nuint bufferSize;
119 public IntPtr buffer;
122 [StructLayout(LayoutKind.Sequential)]
123 internal struct peak_icv_binning_factor
129 [StructLayout(LayoutKind.Sequential)]
130 internal struct peak_icv_capture_information
132 public peak_icv_binning_factor binning_factor;
133 public ulong relative_timestamp;
134 public peak_common_rectangle_u region_of_interest;
135 public double exposure_time;
137 [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
138 public double[] exposure_time_sequence;
142 [MarshalAs(UnmanagedType.ByValArray, SizeConst = 4)]
143 public double[] gain_sequence;
145 public unsafe fixed
byte reserved[24];
149 [StructLayout(LayoutKind.Sequential)]
150 internal struct peak_icv_prism_distortion
152 public unsafe fixed
double coefficients[4];
155 [StructLayout(LayoutKind.Sequential)]
156 internal struct peak_icv_radial_distortion
158 public unsafe fixed
double coefficients[6];
161 [StructLayout(LayoutKind.Sequential)]
162 internal struct peak_icv_tangential_distortion
164 public unsafe fixed
double coefficients[2];
167 [StructLayout(LayoutKind.Sequential)]
168 internal struct peak_icv_tilt_distortion
170 public unsafe fixed
double coefficients[2];
173 [StructLayout(LayoutKind.Sequential)]
174 internal struct peak_icv_distortion_coefficients
176 public peak_icv_radial_distortion radial_distortion;
177 public peak_icv_tangential_distortion tangential_distortion;
178 public peak_icv_prism_distortion prism_distortion;
179 public peak_icv_tilt_distortion tilt_distortion;
182 [StructLayout(LayoutKind.Sequential)]
183 internal record
struct peak_icv_intrinsic_parameters
185 public peak_common_size image_size;
186 public peak_icv_binning_factor binning_factor;
187 public peak_icv_distortion_coefficients distortion_coefficients;
188 public peak_icv_point_f focal_length_pixel_size_ratio;
189 public peak_icv_point_f principle_point;
192 [StructLayout(LayoutKind.Sequential)]
193 internal struct peak_common_rectangle_f
201 [StructLayout(LayoutKind.Sequential)]
202 internal struct peak_icv_interval
207 public peak_icv_interval(
int min,
int max)
214 [StructLayout(LayoutKind.Sequential)]
215 internal struct peak_icv_interval_u
221 [StructLayout(LayoutKind.Sequential)]
222 internal struct peak_icv_interval_f
224 public float minimum;
225 public float maximum;
227 public peak_icv_interval_f(
float min,
float max)
234 [StructLayout(LayoutKind.Sequential)]
235 internal struct peak_icv_range_u
239 public uint increment;
242 [StructLayout(LayoutKind.Sequential)]
243 internal unsafe
struct peak_icv_point_xyz
249 public fixed
float reserved[1];
252 [StructLayout(LayoutKind.Sequential)]
253 internal record
struct peak_icv_extrinsic_parameters
255 public peak_icv_point_xyz rotation;
256 public peak_icv_point_xyz translation;
259 [StructLayout(LayoutKind.Sequential)]
260 internal struct peak_common_size_f
266 [StructLayout(LayoutKind.Sequential)]
267 internal struct peak_icv_drawing_options
271 public unsafe fixed
byte reserved[8];
274 [StructLayout(LayoutKind.Sequential)]
275 internal struct peak_icv_point_xyzi
280 public ushort intensity;
283 [StructLayout(LayoutKind.Sequential)]
284 internal struct peak_icv_point_cloud_save_options
286 public unsafe fixed
byte reserved[64];
289 [StructLayout(LayoutKind.Sequential)]
290 internal struct peak_common_version
295 public uint revision;
298 [StructLayout(LayoutKind.Sequential)]
299 internal struct peak_icv_binary_header
304 public peak_common_version version;
308 [StructLayout(LayoutKind.Sequential)]
309 internal struct peak_icv_calibration_parameters
311 public peak_icv_intrinsic_parameters intrinsic_parameters;
312 public peak_icv_extrinsic_parameters extrinsic_parameters;
315 [StructLayout(LayoutKind.Sequential)]
324 [StructLayout(LayoutKind.Sequential)]
333 [StructLayout(LayoutKind.Sequential)]
334 internal struct peak_icv_calibration_result_save_options
336 public unsafe fixed
byte reserved[64];
339 [StructLayout(LayoutKind.Sequential)]
340 internal struct peak_icv_calibration_parameters_save_options
342 public unsafe fixed
byte reserved[64];
345 internal enum peak_icv_archive_value_type
347 PEAK_ICV_ARCHIVE_VALUE_TYPE_BOOL = 0,
348 PEAK_ICV_ARCHIVE_VALUE_TYPE_BOOL_ARRAY = 1,
349 PEAK_ICV_ARCHIVE_VALUE_TYPE_INT = 2,
350 PEAK_ICV_ARCHIVE_VALUE_TYPE_INT_ARRAY = 3,
351 PEAK_ICV_ARCHIVE_VALUE_TYPE_DOUBLE = 4,
352 PEAK_ICV_ARCHIVE_VALUE_TYPE_DOUBLE_ARRAY = 5,
353 PEAK_ICV_ARCHIVE_VALUE_TYPE_STRING = 6,
354 PEAK_ICV_ARCHIVE_VALUE_TYPE_STRING_ARRAY = 7,
355 PEAK_ICV_ARCHIVE_VALUE_TYPE_ARCHIVE = 8,
356 PEAK_ICV_ARCHIVE_VALUE_TYPE_ARCHIVE_ARRAY = 9
359 [StructLayout(LayoutKind.Sequential)]
373 internal enum peak_icv_color_space
375 PEAK_ICV_COLOR_SPACE_SRGB_D50 = 1,
376 PEAK_ICV_COLOR_SPACE_SRGB_D65 = 2,
377 PEAK_ICV_COLOR_SPACE_CIE_RGB_E = 3,
378 PEAK_ICV_COLOR_SPACE_ECI_RGB_D50 = 4,
379 PEAK_ICV_COLOR_SPACE_ADOBE_RGB_D65 = 5
382 internal enum peak_icv_chromatic_adaption_algorithm
384 PEAK_ICV_CHROMATIC_ADAPTION_ALGORITHM_LEGACY = 1,
385 PEAK_ICV_CHROMATIC_ADAPTION_ALGORITHM_BRADFORD = 2
388 internal enum peak_icv_gain_type
390 PEAK_ICV_GAIN_TYPE_MASTER = 0,
391 PEAK_ICV_GAIN_TYPE_RED = 1,
392 PEAK_ICV_GAIN_TYPE_GREEN = 2,
393 PEAK_ICV_GAIN_TYPE_BLUE = 3
396 internal enum peak_icv_preprocessing_transformation_rotation_angle
398 PEAK_ICV_PREPROCESSING_TRANSFORMATION_ROTATION_NONE = 0,
399 PEAK_ICV_PREPROCESSING_TRANSFORMATION_ROTATION_90_DEGREE_COUNTERCLOCKWISE = 90,
400 PEAK_ICV_PREPROCESSING_TRANSFORMATION_ROTATION_180_DEGREE = 180,
401 PEAK_ICV_PREPROCESSING_TRANSFORMATION_ROTATION_90_DEGREE_CLOCKWISE = 270
404 [StructLayout(LayoutKind.Sequential)]
405 internal struct peak_icv_preprocessing_transformation_parameters
407 [MarshalAs(UnmanagedType.I1)]
public bool mirror_left_right;
408 [MarshalAs(UnmanagedType.I1)]
public bool mirror_up_down;
409 public peak_icv_preprocessing_transformation_rotation_angle rotation_angle;
411 public peak_icv_preprocessing_transformation_parameters(
bool mirrorLeftRight,
bool mirrorUpDown,
412 peak_icv_preprocessing_transformation_rotation_angle rotationAngle)
414 mirror_left_right = mirrorLeftRight;
415 mirror_up_down = mirrorUpDown;
416 rotation_angle = rotationAngle;
420 internal enum peak_icv_downsampling_mode
422 PEAK_ICV_BINNING_AVERAGE = 0,
423 PEAK_ICV_BINNING_SUM = 1,
424 PEAK_ICV_DECIMATION = 2
427 [StructLayout(LayoutKind.Sequential)]
Represents a 2D point with floating-point coordinates.
Represents a 2D vector with floating-point values.
PixelFormat
Each enumerator represents a specific pixel layout and bit-depth, used for interpreting raw image dat...
unsafe fixed byte reserved[40]
peak_icv_point_f position
peak_icv_point_f direction