OrbbecSDK 2.1.1
OrbbecSDK: Software-Development-Kit for Orbbec 3D Cameras
Loading...
Searching...
No Matches
ob::Config Class Reference

Config class for configuring pipeline parameters. More...

#include <Pipeline.hpp>

Public Member Functions

 Config ()
 Construct a new Config object.
 
 Config (ob_config_t *impl)
 
 ~Config () noexcept
 Destroy the Config object.
 
ob_config_t * getImpl () const
 
void enableStream (OBStreamType streamType) const
 enable a stream with a specific stream type
 
void enableStream (OBSensorType sensorType) const
 Enable a stream with a specific sensor type.
 
void enableStream (std::shared_ptr< const StreamProfile > streamProfile) const
 Enable a stream to be used in the pipeline.
 
void enableVideoStream (OBStreamType streamType, uint32_t width=OB_WIDTH_ANY, uint32_t height=OB_HEIGHT_ANY, uint32_t fps=OB_FPS_ANY, OBFormat format=OB_FORMAT_ANY) const
 Enable a video stream to be used in the pipeline.
 
void enableVideoStream (OBSensorType sensorType, uint32_t width=OB_WIDTH_ANY, uint32_t height=OB_HEIGHT_ANY, uint32_t fps=OB_FPS_ANY, OBFormat format=OB_FORMAT_ANY) const
 Enable a video stream to be used in the pipeline.
 
void enableAccelStream (OBAccelFullScaleRange fullScaleRange=OB_ACCEL_FULL_SCALE_RANGE_ANY, OBAccelSampleRate sampleRate=OB_ACCEL_SAMPLE_RATE_ANY) const
 Enable an accelerometer stream to be used in the pipeline.
 
void enableGyroStream (OBGyroFullScaleRange fullScaleRange=OB_GYRO_FULL_SCALE_RANGE_ANY, OBGyroSampleRate sampleRate=OB_GYRO_SAMPLE_RATE_ANY) const
 Enable a gyroscope stream to be used in the pipeline.
 
void enableAllStream ()
 Enable all streams to be used in the pipeline.
 
void disableStream (OBStreamType streamType) const
 Disable a stream to be used in the pipeline.
 
void disableStream (OBSensorType sensorType) const
 Disable a sensor stream to be used in the pipeline.
 
void disableAllStream () const
 Disable all streams to be used in the pipeline.
 
std::shared_ptr< StreamProfileListgetEnabledStreamProfileList () const
 Get the Enabled Stream Profile List.
 
void setAlignMode (OBAlignMode mode) const
 Set the alignment mode.
 
void setDepthScaleRequire (bool enable) const
 Set whether the depth needs to be scaled after setting D2C.
 
void setFrameAggregateOutputMode (OBFrameAggregateOutputMode mode) const
 Set the frame aggregation output mode for the pipeline configuration.
 

Detailed Description

Config class for configuring pipeline parameters.

The Config class provides an interface for configuring pipeline parameters.

Definition at line 28 of file Pipeline.hpp.

Constructor & Destructor Documentation

◆ Config() [1/2]

ob::Config::Config ( )
inline

Construct a new Config object.

Definition at line 36 of file Pipeline.hpp.

◆ Config() [2/2]

ob::Config::Config ( ob_config_t * impl)
inlineexplicit

Definition at line 42 of file Pipeline.hpp.

◆ ~Config()

ob::Config::~Config ( )
inlinenoexcept

Destroy the Config object.

Definition at line 47 of file Pipeline.hpp.

Member Function Documentation

◆ getImpl()

ob_config_t * ob::Config::getImpl ( ) const
inline

Definition at line 53 of file Pipeline.hpp.

◆ enableStream() [1/3]

void ob::Config::enableStream ( OBStreamType streamType) const
inline

enable a stream with a specific stream type

Parameters
streamTypeThe stream type to be enabled

Definition at line 62 of file Pipeline.hpp.

Referenced by enableStream().

◆ enableStream() [2/3]

void ob::Config::enableStream ( OBSensorType sensorType) const
inline

Enable a stream with a specific sensor type.

Will convert sensor type to stream type automatically.

Parameters
sensorTypeThe sensor type to be enabled

Definition at line 74 of file Pipeline.hpp.

◆ enableStream() [3/3]

void ob::Config::enableStream ( std::shared_ptr< const StreamProfile > streamProfile) const
inline

Enable a stream to be used in the pipeline.

Parameters
streamProfileThe stream configuration to be enabled

Definition at line 84 of file Pipeline.hpp.

◆ enableVideoStream() [1/2]

void ob::Config::enableVideoStream ( OBStreamType streamType,
uint32_t width = OB_WIDTH_ANY,
uint32_t height = OB_HEIGHT_ANY,
uint32_t fps = OB_FPS_ANY,
OBFormat format = OB_FORMAT_ANY ) const
inline

Enable a video stream to be used in the pipeline.

This function allows users to enable a video stream with customizable parameters. If no parameters are specified, the stream will be enabled with default resolution settings. Users who wish to set custom resolutions should refer to the product manual, as available resolutions vary by camera model.

Parameters
typeThe video stream type.
widthThe video stream width (default is OB_WIDTH_ANY, which selects the default resolution).
heightThe video stream height (default is OB_HEIGHT_ANY, which selects the default resolution).
fpsThe video stream frame rate (default is OB_FPS_ANY, which selects the default frame rate).
formatThe video stream format (default is OB_FORMAT_ANY, which selects the default format).

Definition at line 104 of file Pipeline.hpp.

Referenced by enableVideoStream().

◆ enableVideoStream() [2/2]

void ob::Config::enableVideoStream ( OBSensorType sensorType,
uint32_t width = OB_WIDTH_ANY,
uint32_t height = OB_HEIGHT_ANY,
uint32_t fps = OB_FPS_ANY,
OBFormat format = OB_FORMAT_ANY ) const
inline

Enable a video stream to be used in the pipeline.

Will convert sensor type to stream type automatically.

Parameters
sensorTypeThe sensor type to be enabled.
widthThe video stream width (default is OB_WIDTH_ANY, which selects the default resolution).
heightThe video stream height (default is OB_HEIGHT_ANY, which selects the default resolution).
fpsThe video stream frame rate (default is OB_FPS_ANY, which selects the default frame rate).
formatThe video stream format (default is OB_FORMAT_ANY, which selects the default format).

Definition at line 121 of file Pipeline.hpp.

◆ enableAccelStream()

void ob::Config::enableAccelStream ( OBAccelFullScaleRange fullScaleRange = OB_ACCEL_FULL_SCALE_RANGE_ANY,
OBAccelSampleRate sampleRate = OB_ACCEL_SAMPLE_RATE_ANY ) const
inline

Enable an accelerometer stream to be used in the pipeline.

This function allows users to enable an accelerometer stream with customizable parameters. If no parameters are specified, the stream will be enabled with default settings. Users who wish to set custom full-scale ranges or sample rates should refer to the product manual, as available settings vary by device model.

Parameters
fullScaleRangeThe full-scale range of the accelerometer (default is OB_ACCEL_FULL_SCALE_RANGE_ANY, which selects the default range).
sampleRateThe sample rate of the accelerometer (default is OB_ACCEL_SAMPLE_RATE_ANY, which selects the default rate).

Definition at line 137 of file Pipeline.hpp.

◆ enableGyroStream()

void ob::Config::enableGyroStream ( OBGyroFullScaleRange fullScaleRange = OB_GYRO_FULL_SCALE_RANGE_ANY,
OBGyroSampleRate sampleRate = OB_GYRO_SAMPLE_RATE_ANY ) const
inline

Enable a gyroscope stream to be used in the pipeline.

This function allows users to enable a gyroscope stream with customizable parameters. If no parameters are specified, the stream will be enabled with default settings. Users who wish to set custom full-scale ranges or sample rates should refer to the product manual, as available settings vary by device model.

Parameters
fullScaleRangeThe full-scale range of the gyroscope (default is OB_GYRO_FULL_SCALE_RANGE_ANY, which selects the default range).
sampleRateThe sample rate of the gyroscope (default is OB_GYRO_SAMPLE_RATE_ANY, which selects the default rate).

Definition at line 154 of file Pipeline.hpp.

◆ enableAllStream()

void ob::Config::enableAllStream ( )
inline

Enable all streams to be used in the pipeline.

Deprecated
Use enableStream(std::shared_ptr<StreamProfile> streamProfile) instead

Definition at line 164 of file Pipeline.hpp.

◆ disableStream() [1/2]

void ob::Config::disableStream ( OBStreamType streamType) const
inline

Disable a stream to be used in the pipeline.

Parameters
streamTypeThe stream configuration to be disabled

Definition at line 175 of file Pipeline.hpp.

Referenced by disableStream().

◆ disableStream() [2/2]

void ob::Config::disableStream ( OBSensorType sensorType) const
inline

Disable a sensor stream to be used in the pipeline.

Will convert sensor type to stream type automatically.

Parameters
sensorType

Definition at line 187 of file Pipeline.hpp.

◆ disableAllStream()

void ob::Config::disableAllStream ( ) const
inline

Disable all streams to be used in the pipeline.

Definition at line 195 of file Pipeline.hpp.

◆ getEnabledStreamProfileList()

std::shared_ptr< StreamProfileList > ob::Config::getEnabledStreamProfileList ( ) const
inline

Get the Enabled Stream Profile List.

Returns
std::shared_ptr<StreamProfileList>

Definition at line 206 of file Pipeline.hpp.

◆ setAlignMode()

void ob::Config::setAlignMode ( OBAlignMode mode) const
inline

Set the alignment mode.

Parameters
modeThe alignment mode

Definition at line 218 of file Pipeline.hpp.

◆ setDepthScaleRequire()

void ob::Config::setDepthScaleRequire ( bool enable) const
inline

Set whether the depth needs to be scaled after setting D2C.

Parameters
enableWhether scaling is required

Definition at line 229 of file Pipeline.hpp.

◆ setFrameAggregateOutputMode()

void ob::Config::setFrameAggregateOutputMode ( OBFrameAggregateOutputMode mode) const
inline

Set the frame aggregation output mode for the pipeline configuration.

The processing strategy when the FrameSet generated by the frame aggregation function does not contain the frames of all opened streams (which can be caused by different frame rates of each stream, or by the loss of frames of one stream): drop directly or output to the user.

Parameters
modeThe frame aggregation output mode to be set (default mode is OB_FRAME_AGGREGATE_OUTPUT_ANY_SITUATION)

Definition at line 242 of file Pipeline.hpp.


The documentation for this class was generated from the following file: