mirror of
https://github.com/orbbec/OrbbecSDK_ROS2.git
synced 2026-10-04 03:57:46 +08:00
Update sdk version to v2.4.1
This commit is contained in:
@@ -211,12 +211,12 @@ OB_EXPORT bool ob_device_preset_list_has_preset(const ob_device_preset_list *pre
|
||||
* @return bool Returns true if the device supports the frame interleave feature.
|
||||
*/
|
||||
OB_EXPORT bool ob_device_is_frame_interleave_supported(const ob_device *device, ob_error **error);
|
||||
/**
|
||||
/**
|
||||
*
|
||||
* @brief load the frame interleave mode according to frame interleavee name.
|
||||
*
|
||||
* @param device The device object.
|
||||
* @param interleave_ae_name The name should be one of the frame interleave names returned by @ref ob_device_get_available_frame_interleave_list.
|
||||
* @param frame_interleave_name The name should be one of the frame interleave names returned by @ref ob_device_get_available_frame_interleave_list.
|
||||
* @param error Log error messages.
|
||||
*/
|
||||
OB_EXPORT void ob_device_load_frame_interleave(ob_device *device, const char *frame_interleave_name, ob_error **error);
|
||||
@@ -230,11 +230,10 @@ OB_EXPORT void ob_device_load_frame_interleave(ob_device *device, const char *fr
|
||||
*/
|
||||
OB_EXPORT ob_device_frame_interleave_list *ob_device_get_available_frame_interleave_list(ob_device *device, ob_error **error);
|
||||
|
||||
|
||||
/**
|
||||
* @brief Delete the available frame interleave list.
|
||||
*
|
||||
* @param interleave_ae_list The available frame interleave list.
|
||||
* @param frame_interleave_list The available frame interleave list.
|
||||
* @param error Log error messages.
|
||||
*/
|
||||
OB_EXPORT void ob_delete_frame_interleave_list(ob_device_frame_interleave_list *frame_interleave_list, ob_error **error);
|
||||
@@ -242,7 +241,7 @@ OB_EXPORT void ob_delete_frame_interleave_list(ob_device_frame_interleave_list *
|
||||
/**
|
||||
* @brief Get the number of frame interleave in the frame interleave list.
|
||||
*
|
||||
* @param interleave_ae_list The available frame interleave list.
|
||||
* @param frame_interleave_list The available frame interleave list.
|
||||
* @param error Log error messages.
|
||||
* @return The number of frame interleave in the frame interleave list.
|
||||
*/
|
||||
@@ -251,7 +250,7 @@ OB_EXPORT uint32_t ob_device_frame_interleave_list_get_count(ob_device_frame_int
|
||||
/**
|
||||
* @brief Get the name of frame interleave in the frame interleave list.
|
||||
*
|
||||
* @param interleave_ae_list The available frame interleave list.
|
||||
* @param frame_interleave_list The available frame interleave list.
|
||||
* @param index The index of frame interleave in the frame interleave list.
|
||||
* @param error Log error messages.
|
||||
* @return The name of frame interleave in the frame interleave list..
|
||||
@@ -261,8 +260,8 @@ OB_EXPORT const char *ob_device_frame_interleave_list_get_name(ob_device_frame_i
|
||||
/**
|
||||
* @brief Check if the interleave ae list has the interleave ae.
|
||||
*
|
||||
* @param interleave_ae_list The available interleave ae list.
|
||||
* @param interleave_ae_name The name of the interleave ae.
|
||||
* @param frame_interleave_list The available interleave ae list.
|
||||
* @param frame_interleave_name The name of the interleave ae.
|
||||
* @param error Log error messages.
|
||||
* @return Whether the interleave ae list has the interleave ae. If true, the interleave ae list has the interleave ae. If false, the interleave ae list does
|
||||
* not have the interleave ae.
|
||||
|
||||
@@ -104,7 +104,7 @@ OB_EXPORT void ob_enable_device_clock_sync(ob_context *context, uint64_t repeat_
|
||||
OB_EXPORT void ob_free_idle_memory(ob_context *context, ob_error **error);
|
||||
|
||||
/**
|
||||
* @brief For linux, there are two ways to enable the UVC backend: libuvc and libusb. This function is used to set the backend type.
|
||||
* @brief For linux, there are two ways to enable the UVC backend: libuvc and v4l2. This function is used to set the backend type.
|
||||
* @brief It is effective when the new device is created.
|
||||
*
|
||||
* @attention This interface is only available for Linux.
|
||||
|
||||
@@ -166,6 +166,26 @@ OB_EXPORT void ob_device_get_structured_data(ob_device *device, ob_property_id p
|
||||
*/
|
||||
OB_EXPORT void ob_device_get_raw_data(ob_device *device, ob_property_id property_id, ob_get_data_callback cb, void *user_data, ob_error **error);
|
||||
|
||||
/**
|
||||
* @brief Set customer data.
|
||||
*
|
||||
* @param[in] device The device object.
|
||||
* @param[in] data The property data to be set.
|
||||
* @param[in] data_size The size of the property to be set,the maximum length cannot exceed 65532 bytes.
|
||||
* @param[out] error Log error messages.
|
||||
*/
|
||||
OB_EXPORT void ob_device_write_customer_data(ob_device *device, const void *data, uint32_t data_size, ob_error **error);
|
||||
|
||||
/**
|
||||
* @brief Get customer data of a device property.
|
||||
*
|
||||
* @param[in] device The device object.
|
||||
* @param[out] data The obtained property data.
|
||||
* @param[out] data_size The size of the obtained property data.
|
||||
* @param[out] error Log error messages.
|
||||
*/
|
||||
OB_EXPORT void ob_device_read_customer_data(ob_device *device, void *data, uint32_t *data_size, ob_error **error);
|
||||
|
||||
/**
|
||||
* @brief Get the number of properties supported by the device.
|
||||
*
|
||||
@@ -305,9 +325,8 @@ OB_EXPORT void ob_device_enable_heartbeat(ob_device *device, bool enable, ob_err
|
||||
* @param[in] send_data The data to be sent to the device.
|
||||
* @param[in] send_data_size The size of the data to be sent to the device.
|
||||
* @param[out] receive_data The data received from the device.
|
||||
* @param[in, out] receive_data_size Pass in the expected size of the receive data, and return the actual size of the received data.
|
||||
* @param[in,out] receive_data_size Pass in the expected size of the receive data, and return the actual size of the received data.
|
||||
* @param error Pointer to an error object that will be set if an error occurs.
|
||||
* @return OB_EXPORT
|
||||
*/
|
||||
OB_EXPORT void ob_device_send_and_receive_data(ob_device *device, const uint8_t *send_data, uint32_t send_data_size, uint8_t *receive_data,
|
||||
uint32_t *receive_data_size, ob_error **error);
|
||||
|
||||
@@ -62,7 +62,7 @@ OB_EXPORT ob_frame *ob_create_frame_from_stream_profile(const ob_stream_profile
|
||||
* no longer needed.
|
||||
*
|
||||
* @param[in] frame_type Frame object type.
|
||||
* @param[in] frame_format Frame object format.
|
||||
* @param[in] format Frame object format.
|
||||
* @param[in] width Frame object width.
|
||||
* @param[in] height Frame object height.
|
||||
* @param[in] stride_bytes Row span in bytes. If 0, the stride is calculated based on the width and format.
|
||||
|
||||
@@ -10,15 +10,15 @@
|
||||
|
||||
#include "Export.h"
|
||||
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
|
||||
#pragma pack(push, 1) // struct 1-byte align
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
|
||||
typedef struct ob_context_t ob_context;
|
||||
typedef struct ob_device_t ob_device;
|
||||
typedef struct ob_device_info_t ob_device_info;
|
||||
@@ -185,6 +185,7 @@ typedef enum {
|
||||
OB_PIXEL_DEPTH = 0, // Depth pixel type, the value of the pixel is the distance from the camera to the object
|
||||
OB_PIXEL_DISPARITY = 2, // Disparity for structured light camera
|
||||
OB_PIXEL_RAW_PHASE = 3, // Raw phase for tof camera
|
||||
OB_PIXEL_TOF_DEPTH = 4, // Depth for tof camera
|
||||
} OBPixelType,
|
||||
ob_pixel_type;
|
||||
|
||||
@@ -192,7 +193,7 @@ typedef enum {
|
||||
* @brief Enumeration value describing the pixel format
|
||||
*/
|
||||
typedef enum {
|
||||
OB_FORMAT_UNKNOWN = -1, /*< unknown format */
|
||||
OB_FORMAT_UNKNOWN = -1, /**< unknown format */
|
||||
OB_FORMAT_YUYV = 0, /**< YUYV format */
|
||||
OB_FORMAT_YUY2 = 1, /**< YUY2 format (the actual format is the same as YUYV) */
|
||||
OB_FORMAT_UYVY = 2, /**< UYVY format */
|
||||
@@ -538,6 +539,10 @@ typedef enum {
|
||||
FORMAT_YUYV_TO_BGRA, /**< YUYV to BGRA */
|
||||
FORMAT_YUYV_TO_Y16, /**< YUYV to Y16 */
|
||||
FORMAT_YUYV_TO_Y8, /**< YUYV to Y8 */
|
||||
FORMAT_RGBA_TO_RGB, /**< RGBA to RGB */
|
||||
FORMAT_BGRA_TO_BGR, /**< BGRA to BGR */
|
||||
FORMAT_Y16_TO_RGB, /**< Y16 to RGB */
|
||||
FORMAT_Y8_TO_RGB, /**< Y8 to RGB */
|
||||
} OBConvertFormat,
|
||||
ob_convert_format;
|
||||
|
||||
@@ -1697,17 +1702,17 @@ typedef enum {
|
||||
} ob_uvc_backend_type,
|
||||
OBUvcBackendType;
|
||||
|
||||
|
||||
/**
|
||||
* @brief The playback status of the media
|
||||
*/
|
||||
typedef enum {
|
||||
OB_PLAYBACK_UNKNOWN ,
|
||||
OB_PLAYBACK_PLAYING, /**< The media is playing */
|
||||
OB_PLAYBACK_PAUSED, /**< The media is paused */
|
||||
OB_PLAYBACK_UNKNOWN,
|
||||
OB_PLAYBACK_PLAYING, /**< The media is playing */
|
||||
OB_PLAYBACK_PAUSED, /**< The media is paused */
|
||||
OB_PLAYBACK_STOPPED, /**< The media is stopped */
|
||||
OB_PLAYBACK_COUNT,
|
||||
} ob_playback_status, OBPlaybackStatus;
|
||||
} ob_playback_status,
|
||||
OBPlaybackStatus;
|
||||
|
||||
// For compatibility
|
||||
#define OB_FRAME_METADATA_TYPE_LASER_POWER_MODE OB_FRAME_METADATA_TYPE_LASER_POWER_LEVEL
|
||||
@@ -1815,7 +1820,7 @@ typedef void(ob_frame_destroy_callback)(uint8_t *buffer, void *user_data);
|
||||
*/
|
||||
typedef void(ob_log_callback)(ob_log_severity severity, const char *message, void *user_data);
|
||||
|
||||
typedef void(*ob_playback_status_changed_callback)(ob_playback_status status, void *user_data);
|
||||
typedef void (*ob_playback_status_changed_callback)(ob_playback_status status, void *user_data);
|
||||
/**
|
||||
* @brief Check if the sensor_type is a video sensor
|
||||
*
|
||||
|
||||
@@ -205,13 +205,13 @@ OB_EXPORT void ob_config_enable_stream_with_stream_profile(ob_config *config, co
|
||||
*
|
||||
* @attention The stream_type should be a video stream type, such as OB_STREAM_IR, OB_STREAM_COLOR, OB_STREAM_DEPTH, etc.
|
||||
*
|
||||
* @param config[in] The pipeline configuration object
|
||||
* @param stream_type[in] The type of the stream to be enabled
|
||||
* @param width[in] The width of the video stream
|
||||
* @param height[in] The height of the video stream
|
||||
* @param fps[in] The frame rate of the video stream
|
||||
* @param format[in] The format of the video stream
|
||||
* @param error[out] Pointer to an error object that will be set if an error occurs.
|
||||
* @param[in] config The pipeline configuration object
|
||||
* @param[in] stream_type The type of the stream to be enabled
|
||||
* @param[in] width The width of the video stream
|
||||
* @param[in] height The height of the video stream
|
||||
* @param[in] fps The frame rate of the video stream
|
||||
* @param[in] format The format of the video stream
|
||||
* @param[out] error Pointer to an error object that will be set if an error occurs.
|
||||
*/
|
||||
OB_EXPORT void ob_config_enable_video_stream(ob_config *config, ob_stream_type stream_type, uint32_t width, uint32_t height, uint32_t fps, ob_format format,
|
||||
ob_error **error);
|
||||
@@ -219,20 +219,20 @@ OB_EXPORT void ob_config_enable_video_stream(ob_config *config, ob_stream_type s
|
||||
/**
|
||||
* @brief Enable accelerometer stream with specified parameters
|
||||
*
|
||||
* @param config[in] The pipeline configuration object
|
||||
* @param full_scale_range[in] The full scale range of the accelerometer
|
||||
* @param sample_rate[in] The sample rate of the accelerometer
|
||||
* @param error[out] Pointer to an error object that will be set if an error occurs.
|
||||
* @param[in] config The pipeline configuration object
|
||||
* @param[in] full_scale_range The full scale range of the accelerometer
|
||||
* @param[in] sample_rate The sample rate of the accelerometer
|
||||
* @param[out] error Pointer to an error object that will be set if an error occurs.
|
||||
*/
|
||||
OB_EXPORT void ob_config_enable_accel_stream(ob_config *config, ob_accel_full_scale_range full_scale_range, ob_accel_sample_rate sample_rate, ob_error **error);
|
||||
|
||||
/**
|
||||
* @brief Enable gyroscope stream with specified parameters
|
||||
*
|
||||
* @param config[in] The pipeline configuration object
|
||||
* @param full_scale_range[in] The full scale range of the gyroscope
|
||||
* @param sample_rate[in] The sample rate of the gyroscope
|
||||
* @param error[out] Pointer to an error object that will be set if an error occurs.
|
||||
* @param[in] config The pipeline configuration object
|
||||
* @param[in] full_scale_range The full scale range of the gyroscope
|
||||
* @param[in] sample_rate The sample rate of the gyroscope
|
||||
* @param[out] error Pointer to an error object that will be set if an error occurs.
|
||||
*/
|
||||
OB_EXPORT void ob_config_enable_gyro_stream(ob_config *config, ob_gyro_full_scale_range full_scale_range, ob_gyro_sample_rate sample_rate, ob_error **error);
|
||||
|
||||
|
||||
@@ -509,6 +509,12 @@ typedef enum {
|
||||
* @brief soft trigger auto capture interval time, use in OB_MULTI_DEVICE_SYNC_MODE_SOFTWARE_TRIGGERING mode
|
||||
*/
|
||||
OB_DEVICE_AUTO_CAPTURE_INTERVAL_TIME_INT = 217,
|
||||
|
||||
/**
|
||||
* @brief PTP time synchronization enable
|
||||
*/
|
||||
OB_DEVICE_PTP_CLOCK_SYNC_ENABLE_BOOL = 223,
|
||||
|
||||
/**
|
||||
* @brief Baseline calibration parameters
|
||||
*/
|
||||
@@ -817,6 +823,11 @@ typedef enum {
|
||||
* @brief Calibration JSON file read from device (Femto Mega, read only)
|
||||
*/
|
||||
OB_RAW_DATA_CAMERA_CALIB_JSON_FILE = 4029,
|
||||
|
||||
/**
|
||||
* @brief Confidence degree
|
||||
*/
|
||||
OB_PROP_DEBUG_ESGM_CONFIDENCE_FLOAT = 5013,
|
||||
} OBPropertyID,
|
||||
ob_property_id;
|
||||
|
||||
|
||||
@@ -134,13 +134,23 @@ OB_EXPORT ob_extrinsic ob_stream_profile_get_extrinsic_to(const ob_stream_profil
|
||||
/**
|
||||
* @brief Set the extrinsic for source stream to target stream
|
||||
*
|
||||
* @param[in] profile Stream profile object
|
||||
* @param[in] source Stream profile object
|
||||
* @param[in] target Target stream type
|
||||
* @param[in] extrinsic The extrinsic
|
||||
* @param[out] error Pointer to an error object that will be set if an error occurs.
|
||||
*/
|
||||
OB_EXPORT void ob_stream_profile_set_extrinsic_to(ob_stream_profile *source, const ob_stream_profile *target, ob_extrinsic extrinsic, ob_error **error);
|
||||
|
||||
/**
|
||||
* @brief Set the extrinsic for source stream to target stream type
|
||||
*
|
||||
* @param[in] source Source stream profile
|
||||
* @param[in] type Target stream type
|
||||
* @param[out] error Pointer to an error object that will be set if an error occurs.
|
||||
* @return ob_extrinsic The extrinsic
|
||||
*/
|
||||
OB_EXPORT void ob_stream_profile_set_extrinsic_to_type(ob_stream_profile *source, const ob_stream_type type, ob_extrinsic extrinsic, ob_error **error);
|
||||
|
||||
/**
|
||||
* @brief Get the frame rate of the video stream
|
||||
*
|
||||
@@ -235,7 +245,7 @@ OB_EXPORT ob_disparity_param ob_disparity_based_stream_profile_get_disparity_par
|
||||
* @brief Set the disparity process param of the disparity stream.
|
||||
*
|
||||
* @param[in] profile Stream profile object. If the profile is not for the disparity stream, an error will be returned.
|
||||
* @param[in] intrinsic The disparity process param of the disparity stream.
|
||||
* @param[in] param The disparity process param of the disparity stream.
|
||||
* @param[out] error Pointer to an error object that will be set if an error occurs.
|
||||
*/
|
||||
OB_EXPORT void ob_disparity_based_stream_profile_set_disparity_param(ob_stream_profile *profile, ob_disparity_param param, ob_error **error);
|
||||
|
||||
@@ -24,10 +24,9 @@ OB_EXPORT bool ob_transformation_3d_to_3d(const OBPoint3f source_point3f, OBExtr
|
||||
/**
|
||||
* @brief Transform a 2d pixel coordinate with an associated depth value of the source camera into a 3d point of the target coordinate system.
|
||||
*
|
||||
* @param[in] source_intrinsic Source intrinsic parameters
|
||||
* @param[in] source_distortion Source distortion parameters
|
||||
* @param[in] source_point2f Source 2d point value
|
||||
* @param[in] source_depth_pixel_value The depth of sourcePoint2f in millimeters
|
||||
* @param[in] source_intrinsic Source intrinsic parameters
|
||||
* @param[in] extrinsic Transformation matrix from source to target
|
||||
* @param[out] target_point3f Target 3d point value
|
||||
* @param[out] error Pointer to an error object that will be set if an error occurs.
|
||||
|
||||
Reference in New Issue
Block a user