Intel® RealSense™ Cross Platform API  2.13.0
Intel Realsense Cross-platform API
Classes | Typedefs | Enumerations | Functions
rs_internal.h File Reference

Exposes RealSense internal functionality for C compilers. More...

#include "rs_types.h"
#include "rs_context.h"
#include "rs_sensor.h"
#include "rs_frame.h"
#include "rs_option.h"

Go to the source code of this file.

Classes

struct  rs2_video_stream
 All the parameters are requaired to defind video stream. More...
 
struct  rs2_software_video_frame
 All the parameters are requaired to define video frame. More...
 

Typedefs

typedef enum rs2_recording_mode rs2_recording_mode
 
typedef struct rs2_video_stream rs2_video_stream
 All the parameters are requaired to defind video stream. More...
 
typedef struct rs2_software_video_frame rs2_software_video_frame
 All the parameters are requaired to define video frame. More...
 

Enumerations

enum  rs2_recording_mode { RS2_RECORDING_MODE_BLANK_FRAMES, RS2_RECORDING_MODE_COMPRESSED, RS2_RECORDING_MODE_BEST_QUALITY, RS2_RECORDING_MODE_COUNT }
 

Functions

rs2_contextrs2_create_recording_context (int api_version, const char *filename, const char *section, rs2_recording_mode mode, rs2_error **error)
 
rs2_contextrs2_create_mock_context (int api_version, const char *filename, const char *section, rs2_error **error)
 
rs2_devicers2_create_software_device (rs2_error **error)
 
rs2_sensorrs2_software_device_add_sensor (rs2_device *dev, const char *sensor_name, rs2_error **error)
 
void rs2_software_sensor_on_video_frame (rs2_sensor *sensor, rs2_software_video_frame frame, rs2_error **error)
 
void rs2_software_device_create_matcher (rs2_device *dev, rs2_matchers matcher, rs2_error **error)
 
rs2_stream_profilers2_software_sensor_add_video_stream (rs2_sensor *sensor, rs2_video_stream video_stream, rs2_error **error)
 
void rs2_software_sensor_add_read_only_option (rs2_sensor *sensor, rs2_option option, float val, rs2_error **error)
 
void rs2_software_sensor_update_read_only_option (rs2_sensor *sensor, rs2_option option, float val, rs2_error **error)
 

Detailed Description

Exposes RealSense internal functionality for C compilers.

Typedef Documentation

◆ rs2_recording_mode

librealsense Recorder is intended for effective unit-testing Currently supports three modes of operation:

◆ rs2_software_video_frame

All the parameters are requaired to define video frame.

◆ rs2_video_stream

All the parameters are requaired to defind video stream.

Enumeration Type Documentation

◆ rs2_recording_mode

librealsense Recorder is intended for effective unit-testing Currently supports three modes of operation:

Enumerator
RS2_RECORDING_MODE_BLANK_FRAMES 
RS2_RECORDING_MODE_COMPRESSED 
RS2_RECORDING_MODE_BEST_QUALITY 
RS2_RECORDING_MODE_COUNT 

Function Documentation

◆ rs2_create_mock_context()

rs2_context* rs2_create_mock_context ( int  api_version,
const char *  filename,
const char *  section,
rs2_error **  error 
)

Create librealsense context that given a file will respond to calls exactly as the recording did if the user calls a method that was either not called during recording or violates causality of the recording error will be thrown

Parameters
[in]api_versionrealsense API version as provided by RS2_API_VERSION macro
[in]filenamestring representing the name of the file to play back from
[in]sectionstring representing the name of the section within existing recording
[out]errorif non-null, receives any error that occurs during this call, otherwise, errors are ignored
Returns
context object, should be released by rs2_delete_context

◆ rs2_create_recording_context()

rs2_context* rs2_create_recording_context ( int  api_version,
const char *  filename,
const char *  section,
rs2_recording_mode  mode,
rs2_error **  error 
)

Create librealsense context that will try to record all operations over librealsense into a file

Parameters
[in]api_versionrealsense API version as provided by RS2_API_VERSION macro
[in]filenamestring representing the name of the file to record
[in]sectionstring representing the name of the section within existing recording
[out]errorif non-null, receives any error that occurs during this call, otherwise, errors are ignored
Returns
context object, should be released by rs2_delete_context

◆ rs2_create_software_device()

rs2_device* rs2_create_software_device ( rs2_error **  error)

Create software device to enable use librealsense logic without getting data from backend but inject the data from outside

Parameters
[out]errorif non-null, receives any error that occurs during this call, otherwise, errors are ignored
Returns
software device object, should be released by rs2_delete_device

◆ rs2_software_device_add_sensor()

rs2_sensor* rs2_software_device_add_sensor ( rs2_device dev,
const char *  sensor_name,
rs2_error **  error 
)

Add sensor to the software device

Parameters
[in]devthe software device
[in]sensor_namethe name of the sensor
[out]errorif non-null, receives any error that occurs during this call, otherwise, errors are ignored
Returns
software sensor object, should be released by rs2_delete_sensor

◆ rs2_software_device_create_matcher()

void rs2_software_device_create_matcher ( rs2_device dev,
rs2_matchers  matcher,
rs2_error **  error 
)

Set the wanted matcher type that will be used by the syncer

Parameters
[in]devthe software device
[in]matchermatcher type
[out]errorif non-null, receives any error that occurs during this call, otherwise, errors are ignored

◆ rs2_software_sensor_add_read_only_option()

void rs2_software_sensor_add_read_only_option ( rs2_sensor sensor,
rs2_option  option,
float  val,
rs2_error **  error 
)

Add read only option to sensor

Parameters
[in]sensorthe software sensor
[in]optionthe wanted option
[in]valthe initial value
[out]errorif non-null, receives any error that occurs during this call, otherwise, errors are ignored

◆ rs2_software_sensor_add_video_stream()

rs2_stream_profile* rs2_software_sensor_add_video_stream ( rs2_sensor sensor,
rs2_video_stream  video_stream,
rs2_error **  error 
)

Add video stream to sensor

Parameters
[in]sensorthe software sensor
[in]video_streamall the stream components
[out]errorif non-null, receives any error that occurs during this call, otherwise, errors are ignored

◆ rs2_software_sensor_on_video_frame()

void rs2_software_sensor_on_video_frame ( rs2_sensor sensor,
rs2_software_video_frame  frame,
rs2_error **  error 
)

Inject frame to software sonsor

Parameters
[in]sensorthe software sensor
[in]frameall the frame components
[out]errorif non-null, receives any error that occurs during this call, otherwise, errors are ignored

◆ rs2_software_sensor_update_read_only_option()

void rs2_software_sensor_update_read_only_option ( rs2_sensor sensor,
rs2_option  option,
float  val,
rs2_error **  error 
)

Update the read only option added to sensor

Parameters
[in]sensorthe software sensor
[in]optionthe wanted option
[in]valthe wanted value
[out]errorif non-null, receives any error that occurs during this call, otherwise, errors are ignored