Base class for PCD file grabber.
More...
#include <pcl/io/pcd_grabber.h>
Base class for PCD file grabber.
Definition at line 63 of file pcd_grabber.h.
◆ PCDGrabberBase() [1/2]
pcl::PCDGrabberBase::PCDGrabberBase |
( |
const std::string & | pcd_file, |
|
|
float | frames_per_second, |
|
|
bool | repeat ) |
Constructor taking just one PCD file or one TAR file containing multiple PCD files.
- Parameters
-
[in] | pcd_file | path to the PCD file |
[in] | frames_per_second | frames per second. If 0, start() functions like a trigger, publishing the next PCD in the list. |
[in] | repeat | whether to play PCD file in an endless loop or not. |
◆ PCDGrabberBase() [2/2]
pcl::PCDGrabberBase::PCDGrabberBase |
( |
const std::vector< std::string > & | pcd_files, |
|
|
float | frames_per_second, |
|
|
bool | repeat ) |
Constructor taking a list of paths to PCD files, that are played in the order they appear in the list.
- Parameters
-
[in] | pcd_files | vector of paths to PCD files. |
[in] | frames_per_second | frames per second. If 0, start() functions like a trigger, publishing the next PCD in the list. |
[in] | repeat | whether to play PCD file in an endless loop or not. |
◆ ~PCDGrabberBase()
pcl::PCDGrabberBase::~PCDGrabberBase |
( |
| ) |
|
|
noexcept |
◆ getCloudAt()
bool pcl::PCDGrabberBase::getCloudAt |
( |
std::size_t | idx, |
|
|
pcl::PCLPointCloud2 & | blob, |
|
|
Eigen::Vector4f & | origin, |
|
|
Eigen::Quaternionf & | orientation ) const |
Get cloud (in ROS form) at a particular location.
◆ getFramesPerSecond()
float pcl::PCDGrabberBase::getFramesPerSecond |
( |
| ) |
const |
|
overridevirtual |
Returns the frames_per_second.
0 if grabber is trigger-based
Implements pcl::Grabber.
◆ getName()
std::string pcl::PCDGrabberBase::getName |
( |
| ) |
const |
|
overridevirtual |
◆ isRepeatOn()
bool pcl::PCDGrabberBase::isRepeatOn |
( |
| ) |
const |
Returns whether the repeat flag is on.
◆ isRunning()
bool pcl::PCDGrabberBase::isRunning |
( |
| ) |
const |
|
overridevirtual |
Indicates whether the grabber is streaming or not.
- Returns
- true if grabber is started and hasn't run out of PCD files.
Implements pcl::Grabber.
◆ numFrames()
std::size_t pcl::PCDGrabberBase::numFrames |
( |
| ) |
const |
◆ rewind()
Rewinds to the first PCD file in the list.
◆ start()
void pcl::PCDGrabberBase::start |
( |
| ) |
|
|
overridevirtual |
Starts playing the list of PCD files if frames_per_second is > 0.
Otherwise it works as a trigger: publishes only the next PCD file in the list.
Implements pcl::Grabber.
◆ stop()
void pcl::PCDGrabberBase::stop |
( |
| ) |
|
|
overridevirtual |
Stops playing the list of PCD files if frames_per_second is > 0.
Otherwise the method has no effect.
Implements pcl::Grabber.
◆ trigger()
Triggers a callback with new data.
The documentation for this class was generated from the following file: