Program Listing for File rs_frame.h
↰ Return to documentation for file (include/librealsense2/h/rs_frame.h
)
/* License: Apache 2.0. See LICENSE file in root directory.
Copyright(c) 2017 Intel Corporation. All Rights Reserved. */
#ifndef LIBREALSENSE_RS2_FRAME_H
#define LIBREALSENSE_RS2_FRAME_H
#ifdef __cplusplus
extern "C" {
#endif
#include "rs_types.h"
typedef enum rs2_timestamp_domain
{
RS2_TIMESTAMP_DOMAIN_HARDWARE_CLOCK,
RS2_TIMESTAMP_DOMAIN_SYSTEM_TIME,
RS2_TIMESTAMP_DOMAIN_GLOBAL_TIME,
RS2_TIMESTAMP_DOMAIN_COUNT
} rs2_timestamp_domain;
const char* rs2_timestamp_domain_to_string(rs2_timestamp_domain info);
typedef enum rs2_frame_metadata_value
{
RS2_FRAME_METADATA_FRAME_COUNTER ,
RS2_FRAME_METADATA_FRAME_TIMESTAMP ,
RS2_FRAME_METADATA_SENSOR_TIMESTAMP ,
RS2_FRAME_METADATA_ACTUAL_EXPOSURE ,
RS2_FRAME_METADATA_GAIN_LEVEL ,
RS2_FRAME_METADATA_AUTO_EXPOSURE ,
RS2_FRAME_METADATA_WHITE_BALANCE ,
RS2_FRAME_METADATA_TIME_OF_ARRIVAL ,
RS2_FRAME_METADATA_TEMPERATURE ,
RS2_FRAME_METADATA_BACKEND_TIMESTAMP ,
RS2_FRAME_METADATA_ACTUAL_FPS ,
RS2_FRAME_METADATA_FRAME_LASER_POWER ,
RS2_FRAME_METADATA_FRAME_LASER_POWER_MODE ,
RS2_FRAME_METADATA_EXPOSURE_PRIORITY ,
RS2_FRAME_METADATA_EXPOSURE_ROI_LEFT ,
RS2_FRAME_METADATA_EXPOSURE_ROI_RIGHT ,
RS2_FRAME_METADATA_EXPOSURE_ROI_TOP ,
RS2_FRAME_METADATA_EXPOSURE_ROI_BOTTOM ,
RS2_FRAME_METADATA_BRIGHTNESS ,
RS2_FRAME_METADATA_CONTRAST ,
RS2_FRAME_METADATA_SATURATION ,
RS2_FRAME_METADATA_SHARPNESS ,
RS2_FRAME_METADATA_AUTO_WHITE_BALANCE_TEMPERATURE ,
RS2_FRAME_METADATA_BACKLIGHT_COMPENSATION ,
RS2_FRAME_METADATA_HUE ,
RS2_FRAME_METADATA_GAMMA ,
RS2_FRAME_METADATA_MANUAL_WHITE_BALANCE ,
RS2_FRAME_METADATA_POWER_LINE_FREQUENCY ,
RS2_FRAME_METADATA_LOW_LIGHT_COMPENSATION ,
RS2_FRAME_METADATA_FRAME_EMITTER_MODE ,
RS2_FRAME_METADATA_FRAME_LED_POWER ,
RS2_FRAME_METADATA_RAW_FRAME_SIZE ,
RS2_FRAME_METADATA_GPIO_INPUT_DATA ,
RS2_FRAME_METADATA_SEQUENCE_NAME ,
RS2_FRAME_METADATA_SEQUENCE_ID ,
RS2_FRAME_METADATA_SEQUENCE_SIZE ,
//mipi metadata_values
RS2_FRAME_METADATA_TRIGGER ,
RS2_FRAME_METADATA_PRESET ,
RS2_FRAME_METADATA_INPUT_WIDTH ,
RS2_FRAME_METADATA_INPUT_HEIGHT ,
RS2_FRAME_METADATA_SUB_PRESET_INFO ,
RS2_FRAME_METADATA_CALIB_INFO ,
RS2_FRAME_METADATA_CRC ,
RS2_FRAME_METADATA_COUNT
} rs2_frame_metadata_value;
const char* rs2_frame_metadata_to_string(rs2_frame_metadata_value metadata);
const char* rs2_frame_metadata_value_to_string(rs2_frame_metadata_value metadata);
typedef enum rs2_calib_target_type
{
RS2_CALIB_TARGET_RECT_GAUSSIAN_DOT_VERTICES,
RS2_CALIB_TARGET_ROI_RECT_GAUSSIAN_DOT_VERTICES,
RS2_CALIB_TARGET_POS_GAUSSIAN_DOT_VERTICES,
RS2_CALIB_TARGET_COUNT
} rs2_calib_target_type;
const char* rs2_calib_target_type_to_string(rs2_calib_target_type type);
rs2_metadata_type rs2_get_frame_metadata(const rs2_frame* frame, rs2_frame_metadata_value frame_metadata, rs2_error** error);
int rs2_supports_frame_metadata(const rs2_frame* frame, rs2_frame_metadata_value frame_metadata, rs2_error** error);
rs2_timestamp_domain rs2_get_frame_timestamp_domain(const rs2_frame* frameset, rs2_error** error);
rs2_time_t rs2_get_frame_timestamp(const rs2_frame* frame, rs2_error** error);
rs2_sensor* rs2_get_frame_sensor(const rs2_frame* frame, rs2_error** error);
unsigned long long rs2_get_frame_number(const rs2_frame* frame, rs2_error** error);
int rs2_get_frame_data_size(const rs2_frame* frame, rs2_error** error);
const void* rs2_get_frame_data(const rs2_frame* frame, rs2_error** error);
int rs2_get_frame_width(const rs2_frame* frame, rs2_error** error);
int rs2_get_frame_height(const rs2_frame* frame, rs2_error** error);
float rs2_depth_frame_get_units( const rs2_frame* frame, rs2_error** error );
int rs2_get_frame_stride_in_bytes(const rs2_frame* frame, rs2_error** error);
int rs2_get_frame_bits_per_pixel(const rs2_frame* frame, rs2_error** error);
void rs2_frame_add_ref(rs2_frame* frame, rs2_error ** error);
void rs2_release_frame(rs2_frame* frame);
void rs2_keep_frame(rs2_frame* frame);
rs2_vertex* rs2_get_frame_vertices(const rs2_frame* frame, rs2_error** error);
void rs2_export_to_ply(const rs2_frame* frame, const char* fname, rs2_frame* texture, rs2_error** error);
rs2_pixel* rs2_get_frame_texture_coordinates(const rs2_frame* frame, rs2_error** error);
int rs2_get_frame_points_count(const rs2_frame* frame, rs2_error** error);
const rs2_stream_profile* rs2_get_frame_stream_profile(const rs2_frame* frame, rs2_error** error);
int rs2_is_frame_extendable_to(const rs2_frame* frame, rs2_extension extension_type, rs2_error ** error);
rs2_frame* rs2_allocate_synthetic_video_frame(rs2_source* source, const rs2_stream_profile* new_stream, rs2_frame* original,
int new_bpp, int new_width, int new_height, int new_stride, rs2_extension frame_type, rs2_error** error);
rs2_frame* rs2_allocate_synthetic_motion_frame(rs2_source* source, const rs2_stream_profile* new_stream, rs2_frame* original,
rs2_extension frame_type, rs2_error** error);
rs2_frame* rs2_allocate_points(rs2_source* source, const rs2_stream_profile* new_stream, rs2_frame* original, rs2_error** error);
rs2_frame* rs2_allocate_composite_frame(rs2_source* source, rs2_frame** frames, int count, rs2_error** error);
rs2_frame* rs2_extract_frame(rs2_frame* composite, int index, rs2_error** error);
int rs2_embedded_frames_count(rs2_frame* composite, rs2_error** error);
void rs2_synthetic_frame_ready(rs2_source* source, rs2_frame* frame, rs2_error** error);
void rs2_pose_frame_get_pose_data(const rs2_frame* frame, rs2_pose* pose, rs2_error** error);
void rs2_extract_target_dimensions(const rs2_frame* frame, rs2_calib_target_type calib_type, float * target_dims, unsigned int target_dims_size, rs2_error** error);
#ifdef __cplusplus
}
#endif
#endif