Time-of-Flight Library(ToF) 3.4.0
|
|
This class allows you to view/edit the camera settings. More...
#include <camera_config.hpp>
Public Member Functions | |
CameraConfig (tof_camera_config_t ptr=nullptr) | |
Construct from pointer. More... | |
CameraConfig (StringView file_location) | |
Read camera config from disk. More... | |
void | write (StringView file_location) const |
Write camera config to disk. More... | |
CameraType | get_type () const |
Get the camera type. More... | |
void | reset () |
Reset camera config to default. More... | |
size_t | frame_size () const |
Get the amount of frames in the config. More... | |
void | add_frame () |
Add a default frame to the camera config. More... | |
ProcessingConfig | default_processing () const |
Generate default processing config from camera configuration. More... | |
void | erase_frame (size_t frame) |
Erase specified frame. More... | |
std::vector< float > | get_phase_shifts (size_t frame) const |
Get the phase shifts. More... | |
void | set_phase_shifts (size_t frame, const std::vector< float > &phase_shifts) |
Set the phase shifts. More... | |
std::vector< uint32_t > | get_integration_time (size_t frame) const |
Get the integration time. More... | |
void | set_integration_time (size_t frame, const std::vector< uint32_t > &integration_time) |
Set the integration time. More... | |
SensorMode | get_sensor_mode (size_t frame) const |
Get the mode to set the camera's depth sensor to. More... | |
void | set_sensor_mode (size_t frame, SensorMode sensor_mode) |
Set the mode to set the camera's depth sensor to. More... | |
float | get_modulation_frequency (size_t frame) const |
Get the modulation frequency. More... | |
void | set_modulation_frequency (size_t frame, float modulation_frequency) |
Set the modulation frequency. More... | |
float | get_duty_cycle (size_t frame) const |
Get the duty cycle. More... | |
void | set_duty_cycle (size_t frame, float duty_cycle) |
Set the duty cycle. More... | |
Roi | get_roi (size_t frame) const |
Get the region of interest. More... | |
void | set_roi (size_t frame, Roi &roi) |
Set the region of interest. More... | |
uint8_t | get_binning (size_t frame) const |
Get the amount of binning. More... | |
void | set_binning (size_t frame, uint8_t binning) |
Set the amount of binning. More... | |
bool | get_flip (size_t frame) const |
Get is the image flipped. More... | |
void | set_flip (size_t frame, bool flip) |
Set is the image flipped. More... | |
bool | get_mirror (size_t frame) const |
Get is the image mirrored. More... | |
void | set_mirror (size_t frame, bool mirror) |
Set is the image mirrored. More... | |
float | get_gain () const |
Get the image sensor gain. More... | |
void | set_gain (float gain) |
Set the image sensor gain. More... | |
int32_t | get_sync_mode () const |
Get the kind of camera synchronization. More... | |
void | set_sync_mode (int32_t sync_mode) |
Set the kind of camera synchronization. More... | |
std::vector< uint32_t > | maximum_integration_time (size_t frame) |
Get the maximum integration time possible. More... | |
std::vector< uint16_t > | get_dac () const |
Get the DAC gain. More... | |
void | set_dac (const std::vector< uint16_t > &dac) |
Set the DAC gain. More... | |
int32_t | get_mlx_mipi_speed () const |
Get the mipi speed for the MLX75027. More... | |
void | set_mlx_mipi_speed (int32_t mipi_speed) |
Set the mipi speed for the MLX75027. More... | |
uint32_t | get_mlx_preheat (size_t frame) const |
Get the preheat time. More... | |
void | set_mlx_preheat (size_t frame, uint32_t preheat) |
Set the preheat time. More... | |
bool | get_mlx_preheat_enable (size_t frame) const |
Get enable preheat. More... | |
void | set_mlx_preheat_enable (size_t frame, bool enable) |
Set enable preheat. More... | |
void | set_opt_kea_nios_hex (StringView file_location) |
Set the Nios hex for the keaB cameras. More... | |
std::array< int32_t, 2 > | get_opt_kea_sub_quad () const |
Get the opt8241 number of sub and quad frames. More... | |
void | set_opt_kea_sub_quad (const std::array< int32_t, 2 > &subs_quads) |
Set the opt8241 number of sub and quad frames. More... | |
ProcessingConfig | get_processing () const |
Get the processing configuration for when the depth is calculated on camera. More... | |
void | set_processing (ProcessingConfig &processing) |
Set the processing configuration for when the depth is calculated on camera. More... | |
uint32_t | get_frame_time (size_t frame) const |
Get the time this depth frame will take. More... | |
void | set_frame_time (size_t frame, uint32_t frame_time) |
Set the time this depth frame will take. More... | |
std::array< float, 2 > | get_global_phase_offset (size_t frame) const |
Get phase offset for illumination and sensor. More... | |
void | set_global_phase_offset (size_t frame, const std::array< float, 2 > &phase_offset) |
Set phase offset for illumination and sensor. More... | |
uint8_t | get_illumination_mode (size_t frame) const |
Get the illumination mode. More... | |
void | set_illumination_mode (size_t frame, uint8_t illumination_mode) |
Set the illumination mode. More... | |
std::vector< float > | get_image_offsets (size_t frame) const |
Get the image offsets. More... | |
void | set_image_offsets (size_t frame, const std::vector< float > &image_offsets) |
Set the image offsets. More... | |
size_t | get_rgb_width () |
Get the width of the rgb sensor. More... | |
size_t | get_rgb_height () |
Get the height of the rgb sensor. More... | |
TriggerMode | get_trigger_mode () const |
Get the trigger mode. More... | |
void | set_trigger_mode (TriggerMode trigger_mode) |
Set the trigger mode. More... | |
This class allows you to view/edit the camera settings.
Definition at line 122 of file camera_config.hpp.
|
inline |
Construct from pointer.
Definition at line 125 of file camera_config.hpp.
|
inline |
Read camera config from disk.
file_location | Location of camera config on disk |
Definition at line 132 of file camera_config.hpp.
|
inline |
Add a default frame to the camera config.
Definition at line 167 of file camera_config.hpp.
|
inline |
Generate default processing config from camera configuration.
Definition at line 174 of file camera_config.hpp.
|
inline |
Erase specified frame.
frame | Frame number |
Definition at line 184 of file camera_config.hpp.
|
inline |
Get the amount of frames in the config.
Having multiple frames allows you to configure different modulation frequencies or integration times per frame.
Definition at line 161 of file camera_config.hpp.
|
inline |
Get the amount of binning.
frame | Frame number |
Definition at line 299 of file camera_config.hpp.
|
inline |
|
inline |
Get the duty cycle.
frame | Frame number |
Definition at line 264 of file camera_config.hpp.
|
inline |
Get is the image flipped.
frame | Frame number |
Definition at line 315 of file camera_config.hpp.
|
inline |
Get the time this depth frame will take.
This is useful when you want a steady but lower framerate.
frame | Frame number |
Definition at line 496 of file camera_config.hpp.
|
inline |
Get the image sensor gain.
Definition at line 346 of file camera_config.hpp.
|
inline |
Get phase offset for illumination and sensor.
The phase offsets are two floating point values corresponding to the phase delay for the illumination and sensor respectively. The values should be between 0.0 and 1.0 where 0.0 is no phase offset and 1.0 is 360 degree phase offset
frame | Frame number |
Definition at line 516 of file camera_config.hpp.
|
inline |
Get the illumination mode.
frame | Frame number |
Definition at line 539 of file camera_config.hpp.
|
inline |
Get the image offsets.
This configuration is only for sensors with column phase offsets.
frame | Frame number |
Definition at line 557 of file camera_config.hpp.
|
inline |
Get the integration time.
frame | Frame number |
Definition at line 213 of file camera_config.hpp.
|
inline |
Get is the image mirrored.
frame | Frame number |
Definition at line 331 of file camera_config.hpp.
|
inline |
Get the mipi speed for the MLX75027.
Definition at line 404 of file camera_config.hpp.
|
inline |
Get the preheat time.
frame | Frame number |
Definition at line 420 of file camera_config.hpp.
|
inline |
Get enable preheat.
frame | Frame number |
Definition at line 436 of file camera_config.hpp.
|
inline |
Get the modulation frequency.
frame | Frame number |
Definition at line 248 of file camera_config.hpp.
|
inline |
Get the opt8241 number of sub and quad frames.
Definition at line 458 of file camera_config.hpp.
|
inline |
Get the phase shifts.
Value ranges from 0.0 to 1.0 which translates to 0-2 pi
frame | Frame number |
Definition at line 193 of file camera_config.hpp.
|
inline |
Get the processing configuration for when the depth is calculated on camera.
Definition at line 476 of file camera_config.hpp.
|
inline |
Get the height of the rgb sensor.
Definition at line 583 of file camera_config.hpp.
|
inline |
Get the width of the rgb sensor.
Definition at line 576 of file camera_config.hpp.
|
inline |
Get the region of interest.
frame | Frame number |
Definition at line 280 of file camera_config.hpp.
|
inline |
Get the mode to set the camera's depth sensor to.
frame | Frame number |
Definition at line 232 of file camera_config.hpp.
|
inline |
Get the kind of camera synchronization.
Definition at line 361 of file camera_config.hpp.
|
inline |
Get the trigger mode.
Definition at line 590 of file camera_config.hpp.
|
inline |
|
inline |
Get the maximum integration time possible.
frame | Frame number |
Definition at line 377 of file camera_config.hpp.
|
inline |
Reset camera config to default.
Definition at line 152 of file camera_config.hpp.
|
inline |
Set the amount of binning.
frame | Frame number |
binning | Amount of binning 0=none, 1=x2, 2=x4, 3=x8 |
Definition at line 307 of file camera_config.hpp.
|
inline |
|
inline |
Set the duty cycle.
frame | Frame number |
duty_cycle | Duty cycle 0.0 to 1.0 |
Definition at line 272 of file camera_config.hpp.
|
inline |
Set is the image flipped.
frame | Frame number |
flip | Image is flipped |
Definition at line 323 of file camera_config.hpp.
|
inline |
Set the time this depth frame will take.
This is useful when you want a steady but lower framerate.
frame | Frame number |
frame_time | Frame time in micro seconds |
Definition at line 505 of file camera_config.hpp.
|
inline |
Set the image sensor gain.
gain | Image sensor gain |
Definition at line 353 of file camera_config.hpp.
|
inline |
Set phase offset for illumination and sensor.
The phase offsets are two floating point values corresponding to the phase delay for the illumination and sensor respectively. The values should be between 0.0 and 1.0 where 0.0 is no phase offset and 1.0 is 360 degree phase offset
frame | Frame number |
phase_offset | Image is mirrored |
Definition at line 530 of file camera_config.hpp.
|
inline |
Set the illumination mode.
frame | Frame number |
illumination_mode | Illumination mode. 0 is actively modulating, 2 is active low (illumination disabled) and 3 is active high |
Definition at line 548 of file camera_config.hpp.
|
inline |
Set the image offsets.
This configuration is only for sensors with column phase offsets.
frame | Frame number |
image_offsets | The image offset per column in 0.0 to 1.0 |
Definition at line 569 of file camera_config.hpp.
|
inline |
Set the integration time.
frame | Frame number |
integration_time | Integration time in micro seconds |
Definition at line 224 of file camera_config.hpp.
|
inline |
Set is the image mirrored.
frame | Frame number |
mirror | Image is mirrored |
Definition at line 339 of file camera_config.hpp.
|
inline |
Set the mipi speed for the MLX75027.
mipi_speed | The mipi speed. Can only be the values 300, 600, 704, 800 and 960 |
Definition at line 412 of file camera_config.hpp.
|
inline |
Set the preheat time.
frame | Frame number |
preheat | The preheat time |
Definition at line 428 of file camera_config.hpp.
|
inline |
Set enable preheat.
frame | Frame number |
enable | Enable preheating |
Definition at line 444 of file camera_config.hpp.
|
inline |
Set the modulation frequency.
frame | Frame number |
modulation_frequency | Modulation frequency in MHz |
Definition at line 256 of file camera_config.hpp.
|
inline |
Set the Nios hex for the keaB cameras.
file_location | File location of the nios hex file |
Definition at line 451 of file camera_config.hpp.
|
inline |
Set the opt8241 number of sub and quad frames.
subs_quads | Number of subs and quads respectively |
Definition at line 468 of file camera_config.hpp.
|
inline |
Set the phase shifts.
Value ranges from 0.0 to 1.0 which translates to 0-2 pi
frame | Frame number |
phase_shifts | Phase shifts |
Definition at line 205 of file camera_config.hpp.
|
inline |
Set the processing configuration for when the depth is calculated on camera.
processing | The pipeline processing to be done on camera |
Definition at line 487 of file camera_config.hpp.
|
inline |
Set the region of interest.
frame | Frame number |
roi | Region of interest |
Definition at line 291 of file camera_config.hpp.
|
inline |
Set the mode to set the camera's depth sensor to.
frame | Frame number |
sensor_mode | Sensor mode |
Definition at line 240 of file camera_config.hpp.
|
inline |
Set the kind of camera synchronization.
sync_mode | The kind of sync mode. 0 waits for the vsync pulse before starting the next frame. 1 optional vsync 2 is no frame syncing |
Definition at line 369 of file camera_config.hpp.
|
inline |
Set the trigger mode.
trigger_mode | The trigger mode of the camera |
Definition at line 597 of file camera_config.hpp.
|
inline |
Write camera config to disk.
file_location | Location to save camera config to |
Definition at line 139 of file camera_config.hpp.