rs_advanced_mode.cpp
Go to the documentation of this file.
1 /* License: Apache 2.0. See LICENSE file in root directory.
2  Copyright(c) 2017 Intel Corporation. All Rights Reserved. */
3 
4 #include <thread>
5 #include <sstream>
6 
7 #include "types.h"
9 #include "core/advanced_mode.h"
10 #include "api.h"
11 
12 #define STRCASE(T, X) case RS2_##T##_##X: {\
13  static std::string s##T##_##X##_str = make_less_screamy(#X);\
14  return s##T##_##X##_str.c_str(); }
15 
16 namespace librealsense
17 {
18  RS2_ENUM_HELPERS(rs2_rs400_visual_preset, RS400_VISUAL_PRESET)
19 
21  {
22  #define CASE(X) STRCASE(RS400_VISUAL_PRESET, X)
23  switch (value)
24  {
25  CASE(CUSTOM)
26  CASE(HAND)
27  CASE(HIGH_ACCURACY)
28  CASE(HIGH_DENSITY)
29  CASE(MEDIUM_DENSITY)
30  CASE(DEFAULT)
31  CASE(REMOVE_IR_PATTERN)
32  default: assert(!is_valid(value)); return UNKNOWN_VALUE;
33  }
34  #undef CASE
35  }
36 }
37 
38 using namespace librealsense;
39 
41 
43 {
46  advanced_mode->toggle_advanced_mode(enable > 0);
47 }
49 
51 {
55  *enabled = advanced_mode->is_enabled();
56 }
58 
60 {
64  advanced_mode->set_depth_control_group(*group);
65 }
67 
69 {
73  advanced_mode->get_depth_control_group(group, mode);
74 }
76 
78 {
82  advanced_mode->set_rsm(*group);
83 }
85 
87 {
91  advanced_mode->get_rsm(group, mode);
92 }
94 
96 {
100  advanced_mode->set_rau_support_vector_control(*group);
101 }
103 
105 {
109  advanced_mode->get_rau_support_vector_control(group, mode);
110 }
112 
114 {
118  advanced_mode->set_color_control(*group);
119 }
121 
123 {
127  advanced_mode->get_color_control(group, mode);
128 }
130 
132 {
136  advanced_mode->set_rau_color_thresholds_control(*group);
137 }
139 
141 {
145  advanced_mode->get_rau_color_thresholds_control(group, mode);
146 }
148 
150 {
154  advanced_mode->set_slo_color_thresholds_control(*group);
155 }
157 
159 {
163  advanced_mode->get_slo_color_thresholds_control(group, mode);
164 }
166 
168 {
172  advanced_mode->set_slo_penalty_control(*group);
173 }
175 
177 {
181  advanced_mode->get_slo_penalty_control(group, mode);
182 }
184 
186 {
190  advanced_mode->set_hdad(*group);
191 }
193 
195 {
199  advanced_mode->get_hdad(group, mode);
200 }
202 
204 {
208  advanced_mode->set_color_correction(*group);
209 }
211 
213 {
217  advanced_mode->get_color_correction(group, mode);
218 }
220 
222 {
226  advanced_mode->set_depth_table_control(*group);
227 }
229 
231 {
235  advanced_mode->get_depth_table_control(group, mode);
236 }
238 
240 {
244  advanced_mode->set_ae_control(*group);
245 }
247 
249 {
253  advanced_mode->get_ae_control(group, mode);
254 }
256 
258 {
262  advanced_mode->set_census_radius(*group);
263 }
265 
267 {
271  advanced_mode->get_census_radius(group, mode);
272 }
274 
276 {
280  advanced_mode->set_amp_factor(*group);
281 }
283 
285 {
289  advanced_mode->get_amp_factor(group, mode);
290 }
293 
294 void rs2_get_amp_factor(rs2_device* dev, STAFactor* group, int mode, rs2_error** error);
const char * get_string(rs2_rs400_visual_preset value)
void rs2_set_amp_factor(rs2_device *dev, const STAFactor *group, rs2_error **error) BEGIN_API_CALL
typedef void(APIENTRY *GLDEBUGPROC)(GLenum source
void rs2_get_rau_support_vector_control(rs2_device *dev, STRauSupportVectorControl *group, int mode, rs2_error **error) BEGIN_API_CALL
void rs2_get_hdad(rs2_device *dev, STHdad *group, int mode, rs2_error **error) BEGIN_API_CALL
void rs2_get_color_control(rs2_device *dev, STColorControl *group, int mode, rs2_error **error) BEGIN_API_CALL
void rs2_is_enabled(rs2_device *dev, int *enabled, rs2_error **error) BEGIN_API_CALL
void rs2_get_ae_control(rs2_device *dev, STAEControl *group, int mode, rs2_error **error) BEGIN_API_CALL
void rs2_get_slo_color_thresholds_control(rs2_device *dev, STSloColorThresholdsControl *group, int mode, rs2_error **error) BEGIN_API_CALL
void rs2_get_census(rs2_device *dev, STCensusRadius *group, int mode, rs2_error **error) BEGIN_API_CALL
GLfloat value
void rs2_set_rau_thresholds_control(rs2_device *dev, const STRauColorThresholdsControl *group, rs2_error **error) BEGIN_API_CALL
#define CASE(X)
void rs2_set_census(rs2_device *dev, const STCensusRadius *group, rs2_error **error) BEGIN_API_CALL
const char * rs2_rs400_visual_preset_to_string(rs2_rs400_visual_preset preset)
bool is_valid(const plane_3d &p)
Definition: rendering.h:243
#define RS2_ENUM_HELPERS(TYPE, PREFIX)
Definition: src/types.h:514
void rs2_set_ae_control(rs2_device *dev, const STAEControl *group, rs2_error **error) BEGIN_API_CALL
void rs2_set_hdad(rs2_device *dev, const STHdad *group, rs2_error **error) BEGIN_API_CALL
GLenum mode
void rs2_set_depth_table(rs2_device *dev, const STDepthTableControl *group, rs2_error **error) BEGIN_API_CALL
#define HANDLE_EXCEPTIONS_AND_RETURN(R,...)
Definition: api.h:399
GLboolean GLuint group
Definition: glext.h:5688
void rs2_get_amp_factor(rs2_device *dev, STAFactor *group, int mode, rs2_error **error) BEGIN_API_CALL
void rs2_set_rsm(rs2_device *dev, const STRsm *group, rs2_error **error) BEGIN_API_CALL
void rs2_get_rau_thresholds_control(rs2_device *dev, STRauColorThresholdsControl *group, int mode, rs2_error **error) BEGIN_API_CALL
Definition: api.h:28
GLenum GLenum GLsizei const GLuint GLboolean enabled
void rs2_set_color_correction(rs2_device *dev, const STColorCorrection *group, rs2_error **error) BEGIN_API_CALL
void rs2_set_slo_penalty_control(rs2_device *dev, const STSloPenaltyControl *group, rs2_error **error) BEGIN_API_CALL
void rs2_toggle_advanced_mode(rs2_device *dev, int enable, rs2_error **error) BEGIN_API_CALL
#define VALIDATE_INTERFACE(X, T)
Definition: api.h:428
void rs2_set_depth_control(rs2_device *dev, const STDepthControlGroup *group, rs2_error **error) BEGIN_API_CALL
#define BEGIN_API_CALL
Definition: api.h:397
void rs2_get_rsm(rs2_device *dev, STRsm *group, int mode, rs2_error **error) BEGIN_API_CALL
GLboolean enable
Definition: glext.h:5688
void rs2_get_depth_table(rs2_device *dev, STDepthTableControl *group, int mode, rs2_error **error) BEGIN_API_CALL
rs2_rs400_visual_preset
For RS400 devices: provides optimized settings (presets) for specific types of usage.
Definition: rs_option.h:137
void rs2_get_color_correction(rs2_device *dev, STColorCorrection *group, int mode, rs2_error **error) BEGIN_API_CALL
void rs2_set_slo_color_thresholds_control(rs2_device *dev, const STSloColorThresholdsControl *group, rs2_error **error) BEGIN_API_CALL
void rs2_get_depth_control(rs2_device *dev, STDepthControlGroup *group, int mode, rs2_error **error) BEGIN_API_CALL
#define UNKNOWN_VALUE
Definition: src/types.h:74
void rs2_get_slo_penalty_control(rs2_device *dev, STSloPenaltyControl *group, int mode, rs2_error **error) BEGIN_API_CALL
void rs2_set_color_control(rs2_device *dev, const STColorControl *group, rs2_error **error) BEGIN_API_CALL
#define VALIDATE_NOT_NULL(ARG)
Definition: api.h:406
void rs2_set_rau_support_vector_control(rs2_device *dev, const STRauSupportVectorControl *group, rs2_error **error) BEGIN_API_CALL


librealsense2
Author(s): Sergey Dorodnicov , Doron Hirshberg , Mark Horn , Reagan Lopez , Itay Carpis
autogenerated on Mon May 3 2021 02:47:40