| OrbbecSDK 1.5.7 OrbbecSDK: Software-Development-Kit for Orbbec 3D-Sensor devices

- Main Page
- Namespaces
- Classes
- Files

- File List
- File Members

Filter.hpp
Go to the documentation of this file.
1
10 #pragma once
11
12 #include "Types.hpp"
13 #include <functional>
14 #include <memory>
15
16 namespace ob {
17 class Frame;
18
19 typedef std::function<void(std::shared_ptr<Frame>)> FilterCallback;
20
21 class OB_EXTENSION_API Filter {
22 public:
23 Filter();
24
25 virtual ~Filter() = default;
26
34 virtual void reset();
35
49 virtual std::shared_ptr<Frame> process(std::shared_ptr<Frame> frame);
50
63 virtual void pushFrame(std::shared_ptr<Frame> frame);
64
76 virtual void setCallBack(FilterCallback callback);
77
78 protected:
79 std::shared_ptr<FilterImpl> impl_;
80 };
81
82 class OB_EXTENSION_API PointCloudFilter : public Filter {
83 public:
84 PointCloudFilter();
96 void setCreatePointFormat(OBFormat type);
97
109 void setCameraParam(OBCameraParam param);
110
123 void setFrameAlignState(bool state);
124
142 void setPositionDataScaled(float scale);
143
155 void setColorDataNormalization(bool state);
156 };
157
158 class OB_EXTENSION_API FormatConvertFilter : public Filter {
159 public:
160 FormatConvertFilter();
172 void setFormatConvertType(OBConvertFormat type);
173 };
174
175 class OB_EXTENSION_API CompressionFilter : public Filter {
176 public:
177 CompressionFilter();
191 void setCompressionParams(OBCompressionMode mode, void *params);
192 };
193
194 class OB_EXTENSION_API DecompressionFilter : public Filter {
195 public:
196 DecompressionFilter();
197 };
198
199 } // namespace ob
ob::DecompressionFilter
Definition: Filter.hpp:194
OBFormat
OBFormat
Enumeration value describing the pixel format.
Definition: ObTypes.h:221
ob::Frame
Definition: Frame.hpp:45
ob::Filter
Definition: Filter.hpp:21
ob
Definition: Context.hpp:20
OBCompressionMode
OBCompressionMode
Definition: ObTypes.h:779
ob::FormatConvertFilter
Definition: Filter.hpp:158
OBCameraParam
Camera parameters.
Definition: ObTypes.h:434
Types.hpp
Provide SDK structure and enumeration constant definition (depending on libobsensor/h/ObTypes.h)
ob::Filter::impl_
std::shared_ptr< FilterImpl > impl_
Definition: Filter.hpp:79
ob::CompressionFilter
Definition: Filter.hpp:175
OBConvertFormat
OBConvertFormat
format conversion type enumeration
Definition: ObTypes.h:521
ob::FilterCallback
std::function< void(std::shared_ptr< Frame >)> FilterCallback
Definition: Filter.hpp:17
ob::PointCloudFilter
Definition: Filter.hpp:82
OB_EXTENSION_API
#define OB_EXTENSION_API
Definition: ObTypes.h:25