Point Cloud Library (PCL)
1.10.0
|
43 #include <pcl/io/boost.h>
44 #include <pcl/io/grabber.h>
45 #include <pcl/point_cloud.h>
48 #include <librealsense2/rs.hpp>
66 RealSense2Grabber (
const std::string& file_name_or_serial_number =
"",
const bool repeat_playback =
true );
79 device_width_ = width;
80 device_height_ = height;
96 isRunning ()
const override;
100 getFramesPerSecond ()
const override;
104 getName ()
const override {
return std::string (
"RealSense2Grabber" ); }
122 signalsChanged ()
override;
138 convertDepthToPointXYZ (
const rs2::points& points );
145 convertIntensityDepthToPointXYZRGBI (
const rs2::points& points,
const rs2::video_frame& ir );
152 convertRGBDepthToPointXYZRGB (
const rs2::points& points,
const rs2::video_frame& rgb );
159 convertRGBADepthToPointXYZRGBA (
const rs2::points& points,
const rs2::video_frame& rgb );
165 template <
typename Po
intT,
typename Functor>
167 convertRealsensePointsToPointCloud (
const rs2::points& points,
Functor mapColorFunc );
175 getTextureIdx (
const rs2::video_frame & texture,
float u,
float v);
183 getTextureColor (
const rs2::video_frame& texture,
float u,
float v );
191 getTextureIntensity (
const rs2::video_frame& texture,
float u,
float v );
boost::signals2::signal< signal_librealsense_PointXYZ > * signal_PointXYZ
This file defines compatibility wrappers for low level I/O functions.
boost::signals2::signal< signal_librealsense_PointXYZRGB > * signal_PointXYZRGB
boost::signals2::signal< signal_librealsense_PointXYZI > * signal_PointXYZI
boost::signals2::signal< signal_librealsense_PointXYZRGBA > * signal_PointXYZRGBA
float fps_
Calculated FPS for the grabber.
bool quit_
controlling the state of the thread.
Grabber for Intel Realsense 2 SDK devices (D400 series)
std::uint32_t device_width_
Width for the depth and color sensor.
Grabber interface for PCL 1.x device drivers.
void setDeviceOptions(std::uint32_t width, std::uint32_t height, std::uint32_t fps=30)
Set the device options.
std::uint32_t device_height_
Height for the depth and color sensor.
Base functor all the models that need non linear optimization must define their own one and implement...
A structure representing RGB color information.
rs2::pipeline pipe_
Declare RealSense pipeline, encapsulating the actual device and sensors.
shared_ptr< PointCloud< PointT > > Ptr
std::string getName() const override
defined grabber name
bool running_
Is the grabber running.
shared_ptr< const PointCloud< PointT > > ConstPtr
std::thread thread_
handle to the thread
std::string file_name_or_serial_number_
Defines either a file path to a bag file or a realsense device serial number.
bool repeat_playback_
Repeat playback when reading from file.
rs2::pointcloud pc_
Declare pointcloud object, for calculating pointclouds and texture mappings.
std::uint32_t target_fps_
Target FPS for the device.