| OrbbecSDK 1.5.7 OrbbecSDK: Software-Development-Kit for Orbbec 3D-Sensor devices

- 首页
- 命名空间
- 类
- 文件

- 文件列表
- 文件成员

Frame.h
浏览该文件的文档.
1
11 #pragma once
12
13 #ifdef __cplusplus
14 extern "C" {
15 #endif
16
17 #include "ObTypes.h"
18
34 uint64_t ob_frame_index(ob_frame *frame, ob_error **error);
35
51 ob_format ob_frame_format(ob_frame *frame, ob_error **error);
52
68 ob_frame_type ob_frame_get_type(ob_frame *frame, ob_error **error);
69
85 uint64_t ob_frame_time_stamp(ob_frame *frame, ob_error **error);
86
102 uint64_t ob_frame_time_stamp_us(ob_frame *frame, ob_error **error);
103
119 uint64_t ob_frame_system_time_stamp(ob_frame *frame, ob_error **error);
120
136 void *ob_frame_data(ob_frame *frame, ob_error **error);
137
155 uint32_t ob_frame_data_size(ob_frame *frame, ob_error **error);
156
172 uint32_t ob_video_frame_width(ob_frame *frame, ob_error **error);
173
189 uint32_t ob_video_frame_height(ob_frame *frame, ob_error **error);
190
206 void *ob_video_frame_metadata(ob_frame *frame, ob_error **error);
207
223 uint32_t ob_video_frame_metadata_size(ob_frame *frame, ob_error **error);
224
242 uint8_t ob_video_frame_pixel_available_bit_size(ob_frame *frame, ob_error **error);
243
244 /* @brief 查询IR frame的最原始数据来源（即使回放视频，其原始的数据源也是sensor）
245 * @param[in] frame 视频帧对象
246 * @param[out] error 记录错误信息
247 * @return uint8_t 返回
248 * \endif
249 */
250 ob_sensor_type ob_ir_frame_get_source_sensor_type(ob_frame *frame, ob_error **ob_error);
251
269 float ob_depth_frame_get_value_scale(ob_frame *frame, ob_error **error);
270
289 float ob_points_frame_get_position_value_scale(ob_frame *frame, ob_error **error);
290
304 void ob_delete_frame(ob_frame *frame, ob_error **error);
305
321 uint32_t ob_frameset_frame_count(ob_frame *frameset, ob_error **error);
322
338 ob_frame *ob_frameset_depth_frame(ob_frame *frameset, ob_error **error);
339
355 ob_frame *ob_frameset_color_frame(ob_frame *frameset, ob_error **error);
356
372 ob_frame *ob_frameset_ir_frame(ob_frame *frameset, ob_error **error);
373
389 ob_frame *ob_frameset_points_frame(ob_frame *frameset, ob_error **error);
390
394 ob_frame *ob_frameset_get_frame(ob_frame *frameset, ob_frame_type frame_type, ob_error **error);
395
411 ob_accel_value ob_accel_frame_value(ob_frame *frame, ob_error **error);
412
428 float ob_accel_frame_temperature(ob_frame *frame, ob_error **error);
429
445 ob_gyro_value ob_gyro_frame_value(ob_frame *frame, ob_error **error);
446
462 float ob_gyro_frame_temperature(ob_frame *frame, ob_error **error);
463
470 void ob_frame_add_ref(ob_frame *frame, ob_error **error);
471
483 ob_frame *ob_create_frame(ob_format frame_format, int width, int height, int stride_bytes, ob_frame_type frame_type, ob_error **error);
484
498 ob_frame *ob_create_frame_from_buffer(ob_format frame_format, uint32_t frame_width, uint32_t frame_height, uint8_t *buffer, uint32_t buffer_size,
499 ob_frame_destroy_callback *buffer_destroy_cb, void *buffer_destroy_context, ob_error **error);
500
507 ob_frame *ob_create_frameset(ob_error **error);
508
517 void ob_frameset_push_frame(ob_frame *frameset, ob_frame_type type, ob_frame *frame, ob_error **error);
518
526 void ob_frame_set_system_time_stamp(ob_frame *frame, uint64_t system_timestamp, ob_error **error);
527
535 void ob_frame_set_device_time_stamp(ob_frame *frame, uint64_t device_timestamp, ob_error **error);
536
544 void ob_frame_set_device_time_stamp_us(ob_frame *frame, uint64_t device_timestamp_us, ob_error **error);
545
546 #ifdef __cplusplus
547 }
548 #endif
ob_frameset_push_frame
void ob_frameset_push_frame(ob_frame *frameset, ob_frame_type type, ob_frame *frame, ob_error **error)
push帧
ob_accel_frame_value
ob_accel_value ob_accel_frame_value(ob_frame *frame, ob_error **error)
获取加速度帧数据
ob_video_frame_pixel_available_bit_size
uint8_t ob_video_frame_pixel_available_bit_size(ob_frame *frame, ob_error **error)
获取像素有效位数（如Y16格式帧，每个像素占16bit，但实际只有低10位是有效位，高6位填充0） ...
ob_gyro_frame_value
ob_gyro_value ob_gyro_frame_value(ob_frame *frame, ob_error **error)
获取陀螺仪帧数据
ob_frameset_frame_count
uint32_t ob_frameset_frame_count(ob_frame *frameset, ob_error **error)
获取帧集合包含的帧数量
ob_sensor_type
enum OBSensorType ob_sensor_type
ob_depth_frame_get_value_scale
float ob_depth_frame_get_value_scale(ob_frame *frame, ob_error **error)
获取深度帧的值缩放系数，深度像素值乘以缩放系数后，可以得到单位为毫米的深度值； 如valueScale=0.1, 某坐标像素值为pixelValue=10000， 则表示深度值value = pixelValue*valueScale = 10000*0.1=1000mm。
ob_frame_data_size
uint32_t ob_frame_data_size(ob_frame *frame, ob_error **error)
获取帧数据大小
ob_frame_get_type
ob_frame_type ob_frame_get_type(ob_frame *frame, ob_error **error)
获取帧类型
ob_frame_format
ob_format ob_frame_format(ob_frame *frame, ob_error **error)
获取帧格式
ob_frame_time_stamp_us
uint64_t ob_frame_time_stamp_us(ob_frame *frame, ob_error **error)
获取帧硬件时间戳us
ob_frame_time_stamp
uint64_t ob_frame_time_stamp(ob_frame *frame, ob_error **error)
获取帧硬件时间戳
ObTypes.h
提供 SDK 常用的结构体、枚举常量定义。
OBAccelValue
加速度计及陀螺仪的数据结构体
Definition: ObTypes.h:611
ob_video_frame_width
uint32_t ob_video_frame_width(ob_frame *frame, ob_error **error)
获取视频帧宽
ob_frame_type
enum OBFrameType ob_frame_type
ob_frameset_points_frame
ob_frame * ob_frameset_points_frame(ob_frame *frameset, ob_error **error)
从帧集合中获取点云数据
ob_frame_system_time_stamp
uint64_t ob_frame_system_time_stamp(ob_frame *frame, ob_error **error)
获取帧系统时间戳
ob_frameset_depth_frame
ob_frame * ob_frameset_depth_frame(ob_frame *frameset, ob_error **error)
从帧集合中获取深度帧
ob_gyro_frame_temperature
float ob_gyro_frame_temperature(ob_frame *frame, ob_error **error)
获取加速度帧采样时温度
ob_frame_set_device_time_stamp_us
void ob_frame_set_device_time_stamp_us(ob_frame *frame, uint64_t device_timestamp_us, ob_error **error)
设置帧的设备时间戳
ob_points_frame_get_position_value_scale
float ob_points_frame_get_position_value_scale(ob_frame *frame, ob_error **error)
获取点云帧的点坐标值缩放系数，点坐标值乘以缩放系数后，可以得到单位为毫米的坐标值； 如scale=0...
ob_frameset_ir_frame
ob_frame * ob_frameset_ir_frame(ob_frame *frameset, ob_error **error)
从帧集合中获取红外帧
ob_create_frame_from_buffer
ob_frame * ob_create_frame_from_buffer(ob_format frame_format, uint32_t frame_width, uint32_t frame_height, uint8_t *buffer, uint32_t buffer_size, ob_frame_destroy_callback *buffer_destroy_cb, void *buffer_destroy_context, ob_error **error)
根据外部创建的Buffer创建帧对象
ob_frame_index
uint64_t ob_frame_index(ob_frame *frame, ob_error **error)
获取帧索引
ob_ir_frame_get_source_sensor_type
ob_sensor_type ob_ir_frame_get_source_sensor_type(ob_frame *frame, ob_error **ob_error)
ob_create_frame
ob_frame * ob_create_frame(ob_format frame_format, int width, int height, int stride_bytes, ob_frame_type frame_type, ob_error **error)
创建空的帧对象
ob_frame_data
void * ob_frame_data(ob_frame *frame, ob_error **error)
获取帧数据
ob_frame
struct CFrameImpl ob_frame
Definition: ObTypes.h:56
ob_frameset_color_frame
ob_frame * ob_frameset_color_frame(ob_frame *frameset, ob_error **error)
从帧集合中获取彩色帧
ob_format
enum OBFormat ob_format
ob_frame_destroy_callback
void( ob_frame_destroy_callback)(void *buffer, void *context)
自定义删除回调，当引用计数为 0 时主动调用
Definition: ObTypes.h:1434
ob_create_frameset
ob_frame * ob_create_frameset(ob_error **error)
创建空的帧集合
ob_frameset_get_frame
ob_frame * ob_frameset_get_frame(ob_frame *frameset, ob_frame_type frame_type, ob_error **error)
ob_frame_set_device_time_stamp
void ob_frame_set_device_time_stamp(ob_frame *frame, uint64_t device_timestamp, ob_error **error)
设置帧的设备时间戳
ob_accel_frame_temperature
float ob_accel_frame_temperature(ob_frame *frame, ob_error **error)
获取加速度帧采样时温度
ob_frame_add_ref
void ob_frame_add_ref(ob_frame *frame, ob_error **error)
增加引用计数
ob_video_frame_height
uint32_t ob_video_frame_height(ob_frame *frame, ob_error **error)
获取视频帧高
ob_delete_frame
void ob_delete_frame(ob_frame *frame, ob_error **error)
删除帧
ob_frame_set_system_time_stamp
void ob_frame_set_system_time_stamp(ob_frame *frame, uint64_t system_timestamp, ob_error **error)
设置帧的系统时间戳
ob_video_frame_metadata_size
uint32_t ob_video_frame_metadata_size(ob_frame *frame, ob_error **error)
获取帧的元数据大小
ob_error
SDK 的对外暴露的错误类，用户可以根据该错误类，获取详细的错误信息
Definition: ObTypes.h:142
ob_video_frame_metadata
void * ob_video_frame_metadata(ob_frame *frame, ob_error **error)
获取帧的元数据