42#include <pcl/visualization/interactor_style.h>
43#include <pcl/visualization/common/common.h>
44#include <pcl/visualization/common/ren_win_interact_map.h>
46class vtkRenderWindowInteractor;
50 namespace visualization
91 template <
typename Po
intT>
bool
116 template <
typename Po
intT>
bool
141 template <
typename Po
intT>
bool
153 const std::string &
id =
"cloud");
162 template <
typename Po
intT>
bool
164 const pcl::index_t index,
const std::string &
id =
"cloud");
176 const std::string &
id =
"cloud");
217 struct ExitMainLoopTimerCallback :
public vtkCommand
219 static ExitMainLoopTimerCallback* New ()
221 return (
new ExitMainLoopTimerCallback);
230 struct ExitCallback :
public vtkCommand
232 ExitCallback () : his () {}
234 static ExitCallback* New ()
236 return (
new ExitCallback);
240 Execute (vtkObject*,
unsigned long event_id,
void*)
override;
242 PCLHistogramVisualizer *his;
254#include <pcl/visualization/impl/histogram_visualizer.hpp>
Iterator class for point clouds with or without given indices.
PCL histogram visualizer main class.
void updateWindowPositions()
Update all window positions on screen so that they fit.
virtual ~PCLHistogramVisualizer()
void setGlobalYRange(float minp, float maxp)
Set the Y range to minp-maxp for all histograms.
bool addFeatureHistogram(const pcl::PCLPointCloud2 &cloud, const std::string &field_name, const pcl::index_t index, const std::string &id="cloud", int win_width=640, int win_height=200)
Add a histogram feature to screen as a separate window.
bool updateFeatureHistogram(const pcl::PCLPointCloud2 &cloud, const std::string &field_name, const pcl::index_t index, const std::string &id="cloud")
Update a histogram feature that is already on screen, with a cloud containing a single histogram.
void setBackgroundColor(const double &r, const double &g, const double &b)
Set the viewport's background color.
void createActor(const vtkSmartPointer< vtkDoubleArray > &xy_array, RenWinInteract &renwinint, const std::string &id, const int win_width, const int win_height)
Create a 2D actor from the given vtkDoubleArray histogram and add it to the screen.
void reCreateActor(const vtkSmartPointer< vtkDoubleArray > &xy_array, RenWinInteract *renwinupd, const int hsize)
Remove the current 2d actor and create a new 2D actor from the given vtkDoubleArray histogram and add...
PCLHistogramVisualizer()
PCL histogram visualizer constructor.
void spinOnce(int time=1)
Spin once method.
bool updateFeatureHistogram(const pcl::PCLPointCloud2 &cloud, const std::string &field_name, const std::string &id="cloud")
Update a histogram feature that is already on screen, with a cloud containing a single histogram.
bool addFeatureHistogram(const pcl::PCLPointCloud2 &cloud, const std::string &field_name, const std::string &id="cloud", int win_width=640, int win_height=200)
Add a histogram feature to screen as a separate window from a cloud containing a single histogram.
std::map< std::string, RenWinInteract > RenWinInteractMap
detail::int_type_t< detail::index_type_size, detail::index_type_signed > index_t
Type used for an index in PCL.