Orbbec SDK K4A Wrapper
Loading...
Searching...
No Matches
k4atypes.h
Go to the documentation of this file.
1
7#ifndef K4ATYPES_H
8#define K4ATYPES_H
9
10#ifdef __cplusplus
11#include <cinttypes>
12#include <cstddef>
13#include <cstring>
14#else
15#include <inttypes.h>
16#include <stddef.h>
17#include <string.h>
18#include <stdbool.h>
19#endif
20
21#ifdef __cplusplus
22extern "C" {
23#endif
24
34#define K4A_DECLARE_HANDLE(_handle_name_) \
35 typedef struct _##_handle_name_ \
36 { \
37 size_t _rsvd; \
38 } *_handle_name_;
39
67
123
174
196
217typedef enum
218{
222
231typedef enum
232{
237
246typedef enum
247{
252
261typedef enum
262{
270
289// Be sure to update k4a_depth_mode_to_string in k4a.c if enum values are added.
290typedef enum
291{
299
308// Be sure to update k4a_color_resolution_to_string in k4a.c if enum values are added.
309typedef enum
310{
319
331// Be sure to update k4a_image_format_to_string in k4a.c if enum values are added.
332typedef enum
333{
346
359
370
387
399
414
425
436
447
459typedef enum
460{
464
477// Be sure to update k4a_fps_to_string in k4a.c if enum values are added.
478typedef enum
479{
484 // add by orbbec
486} k4a_fps_t;
487
506typedef enum
507{
525
541
551
558
565
572
582
592
599
610
625typedef enum
626{
630
639typedef enum
640{
650
661typedef enum
662{
670
684typedef enum
685{
696
705typedef enum
706{
710
719typedef enum
720{
725
746#define K4A_SUCCEEDED(_result_) (_result_ == K4A_RESULT_SUCCEEDED)
747
756#define K4A_FAILED(_result_) (!K4A_SUCCEEDED(_result_))
757
845typedef void(k4a_logging_message_cb_t)(void *context,
846 k4a_log_level_t level,
847 const char *file,
848 const int line,
849 const char *message);
850
871typedef void(k4a_memory_destroy_cb_t)(void *buffer, void *context);
872
895typedef uint8_t *(k4a_memory_allocate_cb_t)(int size, void **context);
896
921{
927
930
933
936
956
967
970
983
990
1005{
1006 float rotation[9];
1007 float translation[3];
1009
1027typedef union
1028{
1030 struct _param
1031 {
1032 float cx;
1033 float cy;
1034 float fx;
1035 float fy;
1036 float k1;
1037 float k2;
1038 float k3;
1039 float k4;
1040 float k5;
1041 float k6;
1042 float codx;
1043 float cody;
1044 float p2;
1045 float p1;
1047 } param;
1048 float v[15];
1050
1069{
1071 unsigned int parameter_count;
1074
1086{
1093
1104{
1116
1120
1129typedef struct _k4a_version_t
1130{
1131 uint32_t major;
1132 uint32_t minor;
1134 uint32_t iteration;
1136
1146{
1155
1164typedef union
1165{
1167 struct _xy
1168 {
1169 float x;
1170 float y;
1171 } xy;
1172 float v[2];
1173} k4a_float2_t;
1174
1183typedef union
1184{
1186 struct _xyz
1187 {
1188 float x;
1189 float y;
1190 float z;
1191 } xyz;
1192 float v[3];
1193} k4a_float3_t;
1194
1203typedef struct _k4a_imu_sample_t
1204{
1211
1234#define K4A_DEVICE_DEFAULT (0)
1235
1244#define K4A_WAIT_INFINITE (-1)
1245
1257static const k4a_device_configuration_t K4A_DEVICE_CONFIG_INIT_DISABLE_ALL = { K4A_IMAGE_FORMAT_COLOR_MJPG,
1261 false,
1262 0,
1264 0,
1265 false };
1266
1271#ifdef __cplusplus
1272}
1273#endif
1274
1275#endif /* K4ATYPES_H */
k4a_transformation_interpolation_type_t
Definition: k4atypes.h:460
k4a_calibration_model_type_t
Definition: k4atypes.h:685
k4a_color_control_mode_t
Definition: k4atypes.h:626
k4a_depth_mode_t
Definition: k4atypes.h:291
k4a_wait_result_t
Definition: k4atypes.h:247
k4a_result_t
Definition: k4atypes.h:218
k4a_wired_sync_mode_t
Definition: k4atypes.h:640
k4a_buffer_result_t
Definition: k4atypes.h:232
k4a_firmware_build_t
Definition: k4atypes.h:706
k4a_log_level_t
Definition: k4atypes.h:262
k4a_calibration_type_t
Definition: k4atypes.h:662
k4a_color_resolution_t
Definition: k4atypes.h:310
k4a_image_format_t
Definition: k4atypes.h:333
k4a_fps_t
Definition: k4atypes.h:479
k4a_firmware_signature_t
Definition: k4atypes.h:720
k4a_color_control_command_t
Definition: k4atypes.h:507
@ K4A_TRANSFORMATION_INTERPOLATION_TYPE_NEAREST
Definition: k4atypes.h:461
@ K4A_TRANSFORMATION_INTERPOLATION_TYPE_LINEAR
Definition: k4atypes.h:462
@ K4A_CALIBRATION_LENS_DISTORTION_MODEL_UNKNOWN
Definition: k4atypes.h:686
@ K4A_CALIBRATION_LENS_DISTORTION_MODEL_POLYNOMIAL_3K
Definition: k4atypes.h:689
@ K4A_CALIBRATION_LENS_DISTORTION_MODEL_BROWN_CONRADY
Definition: k4atypes.h:693
@ K4A_CALIBRATION_LENS_DISTORTION_MODEL_RATIONAL_6KT
Definition: k4atypes.h:691
@ K4A_CALIBRATION_LENS_DISTORTION_MODEL_THETA
Definition: k4atypes.h:687
@ K4A_COLOR_CONTROL_MODE_MANUAL
Definition: k4atypes.h:628
@ K4A_COLOR_CONTROL_MODE_AUTO
Definition: k4atypes.h:627
@ K4A_DEPTH_MODE_WFOV_2X2BINNED
Definition: k4atypes.h:295
@ K4A_DEPTH_MODE_PASSIVE_IR
Definition: k4atypes.h:297
@ K4A_DEPTH_MODE_NFOV_2X2BINNED
Definition: k4atypes.h:293
@ K4A_DEPTH_MODE_WFOV_UNBINNED
Definition: k4atypes.h:296
@ K4A_DEPTH_MODE_OFF
Definition: k4atypes.h:292
@ K4A_DEPTH_MODE_NFOV_UNBINNED
Definition: k4atypes.h:294
@ K4A_WAIT_RESULT_TIMEOUT
Definition: k4atypes.h:250
@ K4A_WAIT_RESULT_SUCCEEDED
Definition: k4atypes.h:248
@ K4A_WAIT_RESULT_FAILED
Definition: k4atypes.h:249
@ K4A_RESULT_SUCCEEDED
Definition: k4atypes.h:219
@ K4A_RESULT_FAILED
Definition: k4atypes.h:220
@ K4A_WIRED_SYNC_MODE_MASTER
Definition: k4atypes.h:642
@ K4A_WIRED_SYNC_MODE_SUBORDINATE
Definition: k4atypes.h:646
@ K4A_WIRED_SYNC_MODE_STANDALONE
Definition: k4atypes.h:641
@ K4A_BUFFER_RESULT_FAILED
Definition: k4atypes.h:234
@ K4A_BUFFER_RESULT_TOO_SMALL
Definition: k4atypes.h:235
@ K4A_BUFFER_RESULT_SUCCEEDED
Definition: k4atypes.h:233
@ K4A_FIRMWARE_BUILD_DEBUG
Definition: k4atypes.h:708
@ K4A_FIRMWARE_BUILD_RELEASE
Definition: k4atypes.h:707
@ K4A_LOG_LEVEL_TRACE
Definition: k4atypes.h:267
@ K4A_LOG_LEVEL_OFF
Definition: k4atypes.h:268
@ K4A_LOG_LEVEL_ERROR
Definition: k4atypes.h:264
@ K4A_LOG_LEVEL_INFO
Definition: k4atypes.h:266
@ K4A_LOG_LEVEL_WARNING
Definition: k4atypes.h:265
@ K4A_LOG_LEVEL_CRITICAL
Definition: k4atypes.h:263
@ K4A_CALIBRATION_TYPE_UNKNOWN
Definition: k4atypes.h:663
@ K4A_CALIBRATION_TYPE_ACCEL
Definition: k4atypes.h:667
@ K4A_CALIBRATION_TYPE_COLOR
Definition: k4atypes.h:665
@ K4A_CALIBRATION_TYPE_DEPTH
Definition: k4atypes.h:664
@ K4A_CALIBRATION_TYPE_GYRO
Definition: k4atypes.h:666
@ K4A_CALIBRATION_TYPE_NUM
Definition: k4atypes.h:668
@ K4A_COLOR_RESOLUTION_720P
Definition: k4atypes.h:312
@ K4A_COLOR_RESOLUTION_1080P
Definition: k4atypes.h:313
@ K4A_COLOR_RESOLUTION_3072P
Definition: k4atypes.h:317
@ K4A_COLOR_RESOLUTION_2160P
Definition: k4atypes.h:316
@ K4A_COLOR_RESOLUTION_OFF
Definition: k4atypes.h:311
@ K4A_COLOR_RESOLUTION_1536P
Definition: k4atypes.h:315
@ K4A_COLOR_RESOLUTION_1440P
Definition: k4atypes.h:314
@ K4A_IMAGE_FORMAT_CUSTOM
Definition: k4atypes.h:445
@ K4A_IMAGE_FORMAT_CUSTOM8
Definition: k4atypes.h:424
@ K4A_IMAGE_FORMAT_IR16
Definition: k4atypes.h:413
@ K4A_IMAGE_FORMAT_DEPTH16
Definition: k4atypes.h:398
@ K4A_IMAGE_FORMAT_CUSTOM16
Definition: k4atypes.h:435
@ K4A_IMAGE_FORMAT_COLOR_MJPG
Definition: k4atypes.h:345
@ K4A_IMAGE_FORMAT_COLOR_YUY2
Definition: k4atypes.h:369
@ K4A_IMAGE_FORMAT_COLOR_BGRA32
Definition: k4atypes.h:386
@ K4A_IMAGE_FORMAT_COLOR_NV12
Definition: k4atypes.h:358
@ K4A_FRAMES_PER_SECOND_5
Definition: k4atypes.h:480
@ K4A_FRAMES_PER_SECOND_30
Definition: k4atypes.h:482
@ K4A_FRAMES_PER_SECOND_25
Definition: k4atypes.h:485
@ K4A_FRAMES_PER_SECOND_15
Definition: k4atypes.h:481
@ K4A_FIRMWARE_SIGNATURE_MSFT
Definition: k4atypes.h:721
@ K4A_FIRMWARE_SIGNATURE_TEST
Definition: k4atypes.h:722
@ K4A_FIRMWARE_SIGNATURE_UNSIGNED
Definition: k4atypes.h:723
@ K4A_COLOR_CONTROL_EXPOSURE_TIME_ABSOLUTE
Definition: k4atypes.h:524
@ K4A_COLOR_CONTROL_GAIN
Definition: k4atypes.h:598
@ K4A_COLOR_CONTROL_AUTO_EXPOSURE_PRIORITY
Definition: k4atypes.h:540
@ K4A_COLOR_CONTROL_POWERLINE_FREQUENCY
Definition: k4atypes.h:608
@ K4A_COLOR_CONTROL_BRIGHTNESS
Definition: k4atypes.h:550
@ K4A_COLOR_CONTROL_SATURATION
Definition: k4atypes.h:564
@ K4A_COLOR_CONTROL_CONTRAST
Definition: k4atypes.h:557
@ K4A_COLOR_CONTROL_SHARPNESS
Definition: k4atypes.h:571
@ K4A_COLOR_CONTROL_WHITEBALANCE
Definition: k4atypes.h:581
@ K4A_COLOR_CONTROL_BACKLIGHT_COMPENSATION
Definition: k4atypes.h:591
void() k4a_memory_destroy_cb_t(void *buffer, void *context)
Definition: k4atypes.h:871
uint8_t *() k4a_memory_allocate_cb_t(int size, void **context)
Definition: k4atypes.h:895
void() k4a_logging_message_cb_t(void *context, k4a_log_level_t level, const char *file, const int line, const char *message)
Definition: k4atypes.h:845
struct _k4a_calibration_extrinsics_t k4a_calibration_extrinsics_t
struct _k4a_imu_sample_t k4a_imu_sample_t
struct _k4a_hardware_version_t k4a_hardware_version_t
struct _k4a_device_configuration_t k4a_device_configuration_t
struct _k4a_calibration_t k4a_calibration_t
struct _k4a_calibration_camera_t k4a_calibration_camera_t
struct _k4a_calibration_intrinsics_t k4a_calibration_intrinsics_t
struct _k4a_version_t k4a_version_t
#define K4A_DECLARE_HANDLE(_handle_name_)
Definition: k4atypes.h:34
k4a_calibration_extrinsics_t extrinsics
Definition: k4atypes.h:1087
k4a_calibration_intrinsics_t intrinsics
Definition: k4atypes.h:1088
k4a_calibration_model_type_t type
Definition: k4atypes.h:1070
k4a_calibration_intrinsic_parameters_t parameters
Definition: k4atypes.h:1072
k4a_color_resolution_t color_resolution
Definition: k4atypes.h:1118
k4a_calibration_camera_t color_camera_calibration
Definition: k4atypes.h:1107
k4a_calibration_extrinsics_t extrinsics[K4A_CALIBRATION_TYPE_NUM][K4A_CALIBRATION_TYPE_NUM]
Definition: k4atypes.h:1115
k4a_calibration_camera_t depth_camera_calibration
Definition: k4atypes.h:1105
k4a_depth_mode_t depth_mode
Definition: k4atypes.h:1117
int32_t depth_delay_off_color_usec
Definition: k4atypes.h:966
k4a_depth_mode_t depth_mode
Definition: k4atypes.h:932
k4a_wired_sync_mode_t wired_sync_mode
Definition: k4atypes.h:969
k4a_color_resolution_t color_resolution
Definition: k4atypes.h:929
uint32_t subordinate_delay_off_master_usec
Definition: k4atypes.h:982
k4a_image_format_t color_format
Definition: k4atypes.h:926
k4a_version_t rgb
Definition: k4atypes.h:1147
k4a_firmware_build_t firmware_build
Definition: k4atypes.h:1152
k4a_version_t audio
Definition: k4atypes.h:1149
k4a_firmware_signature_t firmware_signature
Definition: k4atypes.h:1153
k4a_version_t depth
Definition: k4atypes.h:1148
k4a_version_t depth_sensor
Definition: k4atypes.h:1150
uint64_t acc_timestamp_usec
Definition: k4atypes.h:1207
k4a_float3_t gyro_sample
Definition: k4atypes.h:1208
uint64_t gyro_timestamp_usec
Definition: k4atypes.h:1209
k4a_float3_t acc_sample
Definition: k4atypes.h:1206
uint32_t iteration
Definition: k4atypes.h:1134
uint32_t minor
Definition: k4atypes.h:1132
uint32_t major
Definition: k4atypes.h:1131