PCL Visualizer main class. More...
#include <pcl_visualizer.h>
Classes | |
struct | ExitCallback |
struct | ExitMainLoopTimerCallback |
struct | FPSCallback |
Public Types | |
typedef PointCloudColorHandler < pcl::PCLPointCloud2 > | ColorHandler |
typedef ColorHandler::ConstPtr | ColorHandlerConstPtr |
typedef ColorHandler::Ptr | ColorHandlerPtr |
typedef boost::shared_ptr < const PCLVisualizer > | ConstPtr |
typedef PointCloudGeometryHandler < pcl::PCLPointCloud2 > | GeometryHandler |
typedef GeometryHandler::ConstPtr | GeometryHandlerConstPtr |
typedef GeometryHandler::Ptr | GeometryHandlerPtr |
typedef boost::shared_ptr < PCLVisualizer > | Ptr |
Public Member Functions | |
template<typename P1 , typename P2 > | |
bool | addArrow (const P1 &pt1, const P2 &pt2, double r, double g, double b, const std::string &id="arrow", int viewport=0) |
Add a line arrow segment between two points, and display the distance between them. | |
template<typename P1 , typename P2 > | |
bool | addArrow (const P1 &pt1, const P2 &pt2, double r, double g, double b, bool display_length, const std::string &id="arrow", int viewport=0) |
Add a line arrow segment between two points, and display the distance between them. | |
template<typename P1 , typename P2 > | |
bool | addArrow (const P1 &pt1, const P2 &pt2, double r_line, double g_line, double b_line, double r_text, double g_text, double b_text, const std::string &id="arrow", int viewport=0) |
Add a line arrow segment between two points, and display the distance between them in a given color. | |
bool | addCircle (const pcl::ModelCoefficients &coefficients, const std::string &id="circle", int viewport=0) |
Add a circle from a set of given model coefficients. | |
bool | addCone (const pcl::ModelCoefficients &coefficients, const std::string &id="cone", int viewport=0) |
Add a cone from a set of given model coefficients. | |
void | addCoordinateSystem (double scale=1.0, int viewport=0) |
Adds 3D axes describing a coordinate system to screen at 0,0,0. | |
void | addCoordinateSystem (double scale, float x, float y, float z, int viewport=0) |
Adds 3D axes describing a coordinate system to screen at x, y, z. | |
void | addCoordinateSystem (double scale, const Eigen::Affine3f &t, int viewport=0) |
Adds 3D axes describing a coordinate system to screen at x, y, z, Roll,Pitch,Yaw. | |
template<typename PointT > | |
bool | addCorrespondences (const typename pcl::PointCloud< PointT >::ConstPtr &source_points, const typename pcl::PointCloud< PointT >::ConstPtr &target_points, const std::vector< int > &correspondences, const std::string &id="correspondences", int viewport=0) |
Add the specified correspondences to the display. | |
template<typename PointT > | |
bool | addCorrespondences (const typename pcl::PointCloud< PointT >::ConstPtr &source_points, const typename pcl::PointCloud< PointT >::ConstPtr &target_points, const pcl::Correspondences &correspondences, int nth, const std::string &id="correspondences", int viewport=0) |
Add the specified correspondences to the display. | |
template<typename PointT > | |
bool | addCorrespondences (const typename pcl::PointCloud< PointT >::ConstPtr &source_points, const typename pcl::PointCloud< PointT >::ConstPtr &target_points, const pcl::Correspondences &correspondences, const std::string &id="correspondences", int viewport=0) |
Add the specified correspondences to the display. | |
bool | addCube (const pcl::ModelCoefficients &coefficients, const std::string &id="cube", int viewport=0) |
Add a cube from a set of given model coefficients. | |
bool | addCube (const Eigen::Vector3f &translation, const Eigen::Quaternionf &rotation, double width, double height, double depth, const std::string &id="cube", int viewport=0) |
Add a cube from a set of given model coefficients. | |
bool | addCube (float x_min, float x_max, float y_min, float y_max, float z_min, float z_max, double r=1.0, double g=1.0, double b=1.0, const std::string &id="cube", int viewport=0) |
Add a cube. | |
bool | addCylinder (const pcl::ModelCoefficients &coefficients, const std::string &id="cylinder", int viewport=0) |
Add a cylinder from a set of given model coefficients. | |
template<typename P1 , typename P2 > | |
bool | addLine (const P1 &pt1, const P2 &pt2, const std::string &id="line", int viewport=0) |
Add a line segment from two points. | |
template<typename P1 , typename P2 > | |
bool | addLine (const P1 &pt1, const P2 &pt2, double r, double g, double b, const std::string &id="line", int viewport=0) |
Add a line segment from two points. | |
bool | addLine (const pcl::ModelCoefficients &coefficients, const std::string &id="line", int viewport=0) |
Add a line from a set of given model coefficients. | |
bool | addModelFromPLYFile (const std::string &filename, const std::string &id="PLYModel", int viewport=0) |
Add a PLYmodel as a mesh. | |
bool | addModelFromPLYFile (const std::string &filename, vtkSmartPointer< vtkTransform > transform, const std::string &id="PLYModel", int viewport=0) |
Add a PLYmodel as a mesh and applies given transformation. | |
bool | addModelFromPolyData (vtkSmartPointer< vtkPolyData > polydata, const std::string &id="PolyData", int viewport=0) |
Add a vtkPolydata as a mesh. | |
bool | addModelFromPolyData (vtkSmartPointer< vtkPolyData > polydata, vtkSmartPointer< vtkTransform > transform, const std::string &id="PolyData", int viewport=0) |
Add a vtkPolydata as a mesh. | |
void | addOrientationMarkerWidgetAxes (vtkRenderWindowInteractor *interactor) |
Adds a widget which shows an interactive axes display for orientation. | |
bool | addPlane (const pcl::ModelCoefficients &coefficients, const std::string &id="plane", int viewport=0) |
Add a plane from a set of given model coefficients. | |
bool | addPlane (const pcl::ModelCoefficients &coefficients, double x, double y, double z, const std::string &id="plane", int viewport=0) |
template<typename PointT > | |
bool | addPointCloud (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const std::string &id="cloud", int viewport=0) |
Add a Point Cloud (templated) to screen. | |
template<typename PointT > | |
bool | addPointCloud (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const PointCloudGeometryHandler< PointT > &geometry_handler, const std::string &id="cloud", int viewport=0) |
Add a Point Cloud (templated) to screen. | |
template<typename PointT > | |
bool | addPointCloud (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const GeometryHandlerConstPtr &geometry_handler, const std::string &id="cloud", int viewport=0) |
Add a Point Cloud (templated) to screen. | |
template<typename PointT > | |
bool | addPointCloud (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const PointCloudColorHandler< PointT > &color_handler, const std::string &id="cloud", int viewport=0) |
Add a Point Cloud (templated) to screen. | |
template<typename PointT > | |
bool | addPointCloud (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const ColorHandlerConstPtr &color_handler, const std::string &id="cloud", int viewport=0) |
Add a Point Cloud (templated) to screen. | |
template<typename PointT > | |
bool | addPointCloud (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const GeometryHandlerConstPtr &geometry_handler, const ColorHandlerConstPtr &color_handler, const std::string &id="cloud", int viewport=0) |
Add a Point Cloud (templated) to screen. | |
bool | addPointCloud (const pcl::PCLPointCloud2::ConstPtr &cloud, const GeometryHandlerConstPtr &geometry_handler, const ColorHandlerConstPtr &color_handler, const Eigen::Vector4f &sensor_origin, const Eigen::Quaternion< float > &sensor_orientation, const std::string &id="cloud", int viewport=0) |
Add a binary blob Point Cloud to screen. | |
bool | addPointCloud (const pcl::PCLPointCloud2::ConstPtr &cloud, const GeometryHandlerConstPtr &geometry_handler, const Eigen::Vector4f &sensor_origin, const Eigen::Quaternion< float > &sensor_orientation, const std::string &id="cloud", int viewport=0) |
Add a binary blob Point Cloud to screen. | |
bool | addPointCloud (const pcl::PCLPointCloud2::ConstPtr &cloud, const ColorHandlerConstPtr &color_handler, const Eigen::Vector4f &sensor_origin, const Eigen::Quaternion< float > &sensor_orientation, const std::string &id="cloud", int viewport=0) |
Add a binary blob Point Cloud to screen. | |
template<typename PointT > | |
bool | addPointCloud (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const PointCloudColorHandler< PointT > &color_handler, const PointCloudGeometryHandler< PointT > &geometry_handler, const std::string &id="cloud", int viewport=0) |
Add a Point Cloud (templated) to screen. | |
bool | addPointCloud (const pcl::PointCloud< pcl::PointXYZ >::ConstPtr &cloud, const std::string &id="cloud", int viewport=0) |
Add a PointXYZ Point Cloud to screen. | |
bool | addPointCloud (const pcl::PointCloud< pcl::PointXYZRGB >::ConstPtr &cloud, const std::string &id="cloud", int viewport=0) |
Add a PointXYZRGB Point Cloud to screen. | |
bool | addPointCloud (const pcl::PointCloud< pcl::PointXYZRGBA >::ConstPtr &cloud, const std::string &id="cloud", int viewport=0) |
Add a PointXYZRGBA Point Cloud to screen. | |
template<typename PointT , typename GradientT > | |
bool | addPointCloudIntensityGradients (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const typename pcl::PointCloud< GradientT >::ConstPtr &gradients, int level=100, double scale=1e-6, const std::string &id="cloud", int viewport=0) |
Add the estimated surface intensity gradients of a Point Cloud to screen. | |
template<typename PointNT > | |
bool | addPointCloudNormals (const typename pcl::PointCloud< PointNT >::ConstPtr &cloud, int level=100, float scale=0.02f, const std::string &id="cloud", int viewport=0) |
Add the estimated surface normals of a Point Cloud to screen. | |
template<typename PointT , typename PointNT > | |
bool | addPointCloudNormals (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const typename pcl::PointCloud< PointNT >::ConstPtr &normals, int level=100, float scale=0.02f, const std::string &id="cloud", int viewport=0) |
Add the estimated surface normals of a Point Cloud to screen. | |
bool | addPointCloudPrincipalCurvatures (const pcl::PointCloud< pcl::PointXYZ >::ConstPtr &cloud, const pcl::PointCloud< pcl::Normal >::ConstPtr &normals, const pcl::PointCloud< pcl::PrincipalCurvatures >::ConstPtr &pcs, int level=100, float scale=1.0f, const std::string &id="cloud", int viewport=0) |
Add the estimated principal curvatures of a Point Cloud to screen. | |
template<typename PointT > | |
bool | addPolygon (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, double r, double g, double b, const std::string &id="polygon", int viewport=0) |
Add a polygon (polyline) that represents the input point cloud (connects all points in order) | |
template<typename PointT > | |
bool | addPolygon (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const std::string &id="polygon", int viewport=0) |
Add a polygon (polyline) that represents the input point cloud (connects all points in order) | |
template<typename PointT > | |
bool | addPolygon (const pcl::PlanarPolygon< PointT > &polygon, double r, double g, double b, const std::string &id="polygon", int viewport=0) |
Add a planar polygon that represents the input point cloud (connects all points in order) | |
bool | addPolygonMesh (const pcl::PolygonMesh &polymesh, const std::string &id="polygon", int viewport=0) |
Add a PolygonMesh object to screen. | |
template<typename PointT > | |
bool | addPolygonMesh (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const std::vector< pcl::Vertices > &vertices, const std::string &id="polygon", int viewport=0) |
Add a PolygonMesh object to screen. | |
bool | addPolylineFromPolygonMesh (const pcl::PolygonMesh &polymesh, const std::string &id="polyline", int viewport=0) |
Add a Polygonline from a polygonMesh object to screen. | |
template<typename PointT > | |
bool | addSphere (const PointT ¢er, double radius, const std::string &id="sphere", int viewport=0) |
Add a sphere shape from a point and a radius. | |
template<typename PointT > | |
bool | addSphere (const PointT ¢er, double radius, double r, double g, double b, const std::string &id="sphere", int viewport=0) |
Add a sphere shape from a point and a radius. | |
bool | addSphere (const pcl::ModelCoefficients &coefficients, const std::string &id="sphere", int viewport=0) |
Add a sphere from a set of given model coefficients. | |
bool | addText (const std::string &text, int xpos, int ypos, const std::string &id="", int viewport=0) |
Add a text to screen. | |
bool | addText (const std::string &text, int xpos, int ypos, double r, double g, double b, const std::string &id="", int viewport=0) |
Add a text to screen. | |
bool | addText (const std::string &text, int xpos, int ypos, int fontsize, double r, double g, double b, const std::string &id="", int viewport=0) |
Add a text to screen. | |
template<typename PointT > | |
bool | addText3D (const std::string &text, const PointT &position, double textScale=1.0, double r=1.0, double g=1.0, double b=1.0, const std::string &id="", int viewport=0) |
Add a 3d text to the scene. | |
bool | cameraParamsSet () const |
Checks whether the camera parameters were manually loaded from file. | |
void | close () |
Stop the interaction and close the visualizaton window. | |
void | createInteractor () |
Create the internal Interactor object. | |
void | createViewPort (double xmin, double ymin, double xmax, double ymax, int &viewport) |
Create a new viewport from [xmin,ymin] -> [xmax,ymax]. | |
void | createViewPortCamera (const int viewport) |
Create a new separate camera for the given viewport. | |
bool | getCameraParameters (int argc, char **argv) |
Search for camera parameters at the command line and set them internally. | |
void | getCameras (std::vector< Camera > &cameras) |
Get the current camera parameters. | |
CloudActorMapPtr | getCloudActorMap () |
Return a pointer to the CloudActorMap this visualizer uses. | |
int | getColorHandlerIndex (const std::string &id) |
Get the color handler index of a rendered PointCloud based on its ID. | |
int | getGeometryHandlerIndex (const std::string &id) |
Get the geometry handler index of a rendered PointCloud based on its ID. | |
vtkSmartPointer < PCLVisualizerInteractorStyle > | getInteractorStyle () |
Get a pointer to the current interactor style used. | |
bool | getPointCloudRenderingProperties (int property, double &value, const std::string &id="cloud") |
Get the rendering properties of a PointCloud. | |
vtkSmartPointer < vtkRendererCollection > | getRendererCollection () |
Return a pointer to the underlying VTK Renderer Collection. | |
vtkSmartPointer< vtkRenderWindow > | getRenderWindow () |
Return a pointer to the underlying VTK Render Window used. | |
Eigen::Affine3f | getViewerPose (int viewport=0) |
Get the current viewing pose. | |
void | initCameraParameters () |
Initialize camera parameters with some default values. | |
PCLVisualizer (const std::string &name="", const bool create_interactor=true) | |
PCL Visualizer constructor. | |
PCLVisualizer (int &argc, char **argv, const std::string &name="", PCLVisualizerInteractorStyle *style=PCLVisualizerInteractorStyle::New(), const bool create_interactor=true) | |
PCL Visualizer constructor. | |
boost::signals2::connection | registerAreaPickingCallback (boost::function< void(const pcl::visualization::AreaPickingEvent &)> cb) |
Register a callback function for area picking events. | |
boost::signals2::connection | registerAreaPickingCallback (void(*callback)(const pcl::visualization::AreaPickingEvent &, void *), void *cookie=NULL) |
Register a callback function for area picking events. | |
template<typename T > | |
boost::signals2::connection | registerAreaPickingCallback (void(T::*callback)(const pcl::visualization::AreaPickingEvent &, void *), T &instance, void *cookie=NULL) |
Register a callback function for area picking events. | |
boost::signals2::connection | registerKeyboardCallback (boost::function< void(const pcl::visualization::KeyboardEvent &)> cb) |
Register a callback boost::function for keyboard events. | |
boost::signals2::connection | registerKeyboardCallback (void(*callback)(const pcl::visualization::KeyboardEvent &, void *), void *cookie=NULL) |
Register a callback function for keyboard events. | |
template<typename T > | |
boost::signals2::connection | registerKeyboardCallback (void(T::*callback)(const pcl::visualization::KeyboardEvent &, void *), T &instance, void *cookie=NULL) |
Register a callback function for keyboard events. | |
boost::signals2::connection | registerMouseCallback (boost::function< void(const pcl::visualization::MouseEvent &)> cb) |
Register a callback function for mouse events. | |
boost::signals2::connection | registerMouseCallback (void(*callback)(const pcl::visualization::MouseEvent &, void *), void *cookie=NULL) |
Register a callback function for mouse events. | |
template<typename T > | |
boost::signals2::connection | registerMouseCallback (void(T::*callback)(const pcl::visualization::MouseEvent &, void *), T &instance, void *cookie=NULL) |
Register a callback function for mouse events. | |
boost::signals2::connection | registerPointPickingCallback (boost::function< void(const pcl::visualization::PointPickingEvent &)> cb) |
Register a callback function for point picking events. | |
boost::signals2::connection | registerPointPickingCallback (void(*callback)(const pcl::visualization::PointPickingEvent &, void *), void *cookie=NULL) |
Register a callback function for point picking events. | |
template<typename T > | |
boost::signals2::connection | registerPointPickingCallback (void(T::*callback)(const pcl::visualization::PointPickingEvent &, void *), T &instance, void *cookie=NULL) |
Register a callback function for point picking events. | |
bool | removeAllPointClouds (int viewport=0) |
Remove all point cloud data on screen from the given viewport. | |
bool | removeAllShapes (int viewport=0) |
Remove all 3D shape data on screen from the given viewport. | |
bool | removeCoordinateSystem (int viewport=0) |
Removes a previously added 3D axes (coordinate system) | |
void | removeCorrespondences (const std::string &id="correspondences", int viewport=0) |
Remove the specified correspondences from the display. | |
void | removeOrientationMarkerWidgetAxes () |
Disables the Orientatation Marker Widget so it is removed from the renderer. | |
bool | removePointCloud (const std::string &id="cloud", int viewport=0) |
Removes a Point Cloud from screen, based on a given ID. | |
bool | removePolygonMesh (const std::string &id="polygon", int viewport=0) |
Removes a PolygonMesh from screen, based on a given ID. | |
bool | removeShape (const std::string &id="cloud", int viewport=0) |
Removes an added shape from screen (line, polygon, etc.), based on a given ID. | |
bool | removeText3D (const std::string &id="cloud", int viewport=0) |
Removes an added 3D text from the scene, based on a given ID. | |
void | renderView (int xres, int yres, pcl::PointCloud< pcl::PointXYZ >::Ptr &cloud) |
Renders a virtual scene as seen from the camera viewpoint and returns the rendered point cloud. ATT: This method will only render the scene if only on viewport exists. Otherwise, returns an empty point cloud and exits immediately. | |
void | renderViewTesselatedSphere (int xres, int yres, pcl::PointCloud< pcl::PointXYZ >::CloudVectorType &cloud, std::vector< Eigen::Matrix4f, Eigen::aligned_allocator< Eigen::Matrix4f > > &poses, std::vector< float > &enthropies, int tesselation_level, float view_angle=45, float radius_sphere=1, bool use_vertices=true) |
The purpose of this method is to render a CAD model added to the visualizer from different viewpoints in order to simulate partial views of model. The viewpoint locations are the vertices of a tesselated sphere build from an icosaheadron. The tesselation paremeter controls how many times the triangles of the original icosahedron are divided to approximate the sphere and thus the number of partial view generated for a model, with a tesselation_level of 0, 12 views are generated if use_vertices=true and 20 views if use_vertices=false. | |
void | resetCamera () |
Reset camera parameters and render. | |
void | resetCameraViewpoint (const std::string &id="cloud") |
Reset the camera direction from {0, 0, 0} to the center_{x, y, z} of a given dataset. | |
void | resetStoppedFlag () |
Set the stopped flag back to false. | |
void | saveScreenshot (const std::string &file) |
Save the current rendered image to disk, as a PNG screenshot. | |
void | setBackgroundColor (const double &r, const double &g, const double &b, int viewport=0) |
Set the viewport's background color. | |
void | setCameraClipDistances (double near, double far, int viewport=0) |
Set the camera clipping distances. | |
void | setCameraFieldOfView (double fovy, int viewport=0) |
Set the camera vertical field of view. | |
void | setCameraParameters (const Eigen::Matrix3f &intrinsics, const Eigen::Matrix4f &extrinsics, int viewport=0) |
Set the camera parameters via an intrinsics and and extrinsics matrix. | |
void | setCameraParameters (const Camera &camera, int viewport=0) |
Set the camera parameters by given a full camera data structure. | |
void | setCameraPosition (double pos_x, double pos_y, double pos_z, double view_x, double view_y, double view_z, double up_x, double up_y, double up_z, int viewport=0) |
Set the camera pose given by position, viewpoint and up vector. | |
void | setCameraPosition (double pos_x, double pos_y, double pos_z, double up_x, double up_y, double up_z, int viewport=0) |
Set the camera location and viewup according to the given arguments. | |
void | setFullScreen (bool mode) |
Enables/Disabled the underlying window mode to full screen. | |
bool | setPointCloudRenderingProperties (int property, double val1, double val2, double val3, const std::string &id="cloud", int viewport=0) |
Set the rendering properties of a PointCloud (3x values - e.g., RGB) | |
bool | setPointCloudRenderingProperties (int property, double value, const std::string &id="cloud", int viewport=0) |
Set the rendering properties of a PointCloud. | |
bool | setPointCloudSelected (const bool selected, const std::string &id="cloud") |
Set whether the point cloud is selected or not. | |
void | setPosition (int x, int y) |
Set the position in screen coordinates. | |
void | setRepresentationToPointsForAllActors () |
Changes the visual representation for all actors to points representation. | |
void | setRepresentationToSurfaceForAllActors () |
Changes the visual representation for all actors to surface representation. | |
void | setRepresentationToWireframeForAllActors () |
Changes the visual representation for all actors to wireframe representation. | |
bool | setShapeRenderingProperties (int property, double value, const std::string &id, int viewport=0) |
Set the rendering properties of a shape. | |
bool | setShapeRenderingProperties (int property, double val1, double val2, double val3, const std::string &id, int viewport=0) |
Set the rendering properties of a shape (3x values - e.g., RGB) | |
void | setShowFPS (bool show_fps) |
Sets whether the 2D overlay text showing the framerate of the window is displayed or not. | |
void | setSize (int xw, int yw) |
Set the window size in screen coordinates. | |
void | setupInteractor (vtkRenderWindowInteractor *iren, vtkRenderWindow *win) |
Set up our unique PCL interactor style for a given vtkRenderWindowInteractor object attached to a given vtkRenderWindow. | |
void | setupInteractor (vtkRenderWindowInteractor *iren, vtkRenderWindow *win, vtkInteractorStyle *style) |
Set up PCLVisualizer with custom interactor style for a given vtkRenderWindowInteractor object attached to a given vtkRenderWindow. | |
void | setUseVbos (bool use_vbos) |
Use Vertex Buffer Objects renderers. | |
void | setWindowBorders (bool mode) |
Enables or disable the underlying window borders. | |
void | setWindowName (const std::string &name) |
Set the visualizer window name. | |
void | spin () |
Spin method. Calls the interactor and runs an internal loop. | |
void | spinOnce (int time=1, bool force_redraw=false) |
Spin once method. Calls the interactor and updates the screen once. | |
void | updateCamera () |
Update camera parameters and render. | |
bool | updateColorHandlerIndex (const std::string &id, int index) |
Update/set the color index of a renderered PointCloud based on its ID. | |
template<typename PointT > | |
bool | updateCorrespondences (const typename pcl::PointCloud< PointT >::ConstPtr &source_points, const typename pcl::PointCloud< PointT >::ConstPtr &target_points, const pcl::Correspondences &correspondences, int nth, const std::string &id="correspondences") |
Update the specified correspondences to the display. | |
template<typename PointT > | |
bool | updatePointCloud (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const std::string &id="cloud") |
Updates the XYZ data for an existing cloud object id on screen. | |
template<typename PointT > | |
bool | updatePointCloud (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const PointCloudGeometryHandler< PointT > &geometry_handler, const std::string &id="cloud") |
Updates the XYZ data for an existing cloud object id on screen. | |
template<typename PointT > | |
bool | updatePointCloud (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const PointCloudColorHandler< PointT > &color_handler, const std::string &id="cloud") |
Updates the XYZ data for an existing cloud object id on screen. | |
bool | updatePointCloud (const pcl::PointCloud< pcl::PointXYZ >::ConstPtr &cloud, const std::string &id="cloud") |
Updates the XYZ data for an existing cloud object id on screen. | |
bool | updatePointCloud (const pcl::PointCloud< pcl::PointXYZRGB >::ConstPtr &cloud, const std::string &id="cloud") |
Updates the XYZRGB data for an existing cloud object id on screen. | |
bool | updatePointCloud (const pcl::PointCloud< pcl::PointXYZRGBA >::ConstPtr &cloud, const std::string &id="cloud") |
Updates the XYZRGBA data for an existing cloud object id on screen. | |
bool | updatePointCloudPose (const std::string &id, const Eigen::Affine3f &pose) |
Set the pose of an existing point cloud. | |
template<typename PointT > | |
bool | updatePolygonMesh (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, const std::vector< pcl::Vertices > &vertices, const std::string &id="polygon") |
Update a PolygonMesh object on screen. | |
bool | updatePolygonMesh (const pcl::PolygonMesh &polymesh, const std::string &id="polygon") |
Update a PolygonMesh object on screen. | |
bool | updateShapePose (const std::string &id, const Eigen::Affine3f &pose) |
Set the pose of an existing shape. | |
template<typename PointT > | |
bool | updateSphere (const PointT ¢er, double radius, double r, double g, double b, const std::string &id="sphere") |
Update an existing sphere shape from a point and a radius. | |
bool | updateText (const std::string &text, int xpos, int ypos, const std::string &id="") |
Update a text to screen. | |
bool | updateText (const std::string &text, int xpos, int ypos, double r, double g, double b, const std::string &id="") |
Update a text to screen. | |
bool | updateText (const std::string &text, int xpos, int ypos, int fontsize, double r, double g, double b, const std::string &id="") |
Update a text to screen. | |
bool | wasStopped () const |
Returns true when the user tried to close the window. | |
virtual | ~PCLVisualizer () |
PCL Visualizer destructor. | |
Static Public Member Functions | |
static void | convertToEigenMatrix (const vtkSmartPointer< vtkMatrix4x4 > &vtk_matrix, Eigen::Matrix4f &m) |
Convert vtkMatrix4x4 to an Eigen4f. | |
static void | convertToVtkMatrix (const Eigen::Matrix4f &m, vtkSmartPointer< vtkMatrix4x4 > &vtk_matrix) |
Convert Eigen::Matrix4f to vtkMatrix4x4. | |
static void | convertToVtkMatrix (const Eigen::Vector4f &origin, const Eigen::Quaternion< float > &orientation, vtkSmartPointer< vtkMatrix4x4 > &vtk_matrix) |
Convert origin and orientation to vtkMatrix4x4. | |
Protected Attributes | |
vtkSmartPointer < vtkRenderWindowInteractor > | interactor_ |
The render window interactor. | |
Private Member Functions | |
void | addActorToRenderer (const vtkSmartPointer< vtkProp > &actor, int viewport=0) |
Internal method. Adds a vtk actor to screen. | |
void | allocVtkPolyData (vtkSmartPointer< vtkAppendPolyData > &polydata) |
Allocate a new polydata smartpointer. Internal. | |
void | allocVtkPolyData (vtkSmartPointer< vtkPolyData > &polydata) |
Allocate a new polydata smartpointer. Internal. | |
void | allocVtkUnstructuredGrid (vtkSmartPointer< vtkUnstructuredGrid > &polydata) |
Allocate a new unstructured grid smartpointer. Internal. | |
template<typename PointT > | |
void | convertPointCloudToVTKPolyData (const typename pcl::PointCloud< PointT >::ConstPtr &cloud, vtkSmartPointer< vtkPolyData > &polydata, vtkSmartPointer< vtkIdTypeArray > &initcells) |
Converts a PCL templated PointCloud object to a vtk polydata object. | |
template<typename PointT > | |
void | convertPointCloudToVTKPolyData (const PointCloudGeometryHandler< PointT > &geometry_handler, vtkSmartPointer< vtkPolyData > &polydata, vtkSmartPointer< vtkIdTypeArray > &initcells) |
Converts a PCL templated PointCloud object to a vtk polydata object. | |
void | convertPointCloudToVTKPolyData (const GeometryHandlerConstPtr &geometry_handler, vtkSmartPointer< vtkPolyData > &polydata, vtkSmartPointer< vtkIdTypeArray > &initcells) |
Converts a PCL templated PointCloud object to a vtk polydata object. | |
void | createActorFromVTKDataSet (const vtkSmartPointer< vtkDataSet > &data, vtkSmartPointer< vtkActor > &actor, bool use_scalars=true) |
Internal method. Creates a vtk actor from a vtk polydata object. | |
void | createActorFromVTKDataSet (const vtkSmartPointer< vtkDataSet > &data, vtkSmartPointer< vtkLODActor > &actor, bool use_scalars=true) |
Internal method. Creates a vtk actor from a vtk polydata object. | |
template<typename PointT > | |
bool | fromHandlersToScreen (const PointCloudGeometryHandler< PointT > &geometry_handler, const PointCloudColorHandler< PointT > &color_handler, const std::string &id, int viewport, const Eigen::Vector4f &sensor_origin=Eigen::Vector4f(0, 0, 0, 0), const Eigen::Quaternion< float > &sensor_orientation=Eigen::Quaternion< float >(1, 0, 0, 0)) |
Internal function which converts the information present in the geometric and color handlers into VTK PolyData+Scalars, constructs a vtkActor object, and adds all the required information to the internal cloud_actor_map_ object. | |
template<typename PointT > | |
bool | fromHandlersToScreen (const PointCloudGeometryHandler< PointT > &geometry_handler, const ColorHandlerConstPtr &color_handler, const std::string &id, int viewport, const Eigen::Vector4f &sensor_origin=Eigen::Vector4f(0, 0, 0, 0), const Eigen::Quaternion< float > &sensor_orientation=Eigen::Quaternion< float >(1, 0, 0, 0)) |
Internal function which converts the information present in the geometric and color handlers into VTK PolyData+Scalars, constructs a vtkActor object, and adds all the required information to the internal cloud_actor_map_ object. | |
bool | fromHandlersToScreen (const GeometryHandlerConstPtr &geometry_handler, const ColorHandlerConstPtr &color_handler, const std::string &id, int viewport, const Eigen::Vector4f &sensor_origin=Eigen::Vector4f(0, 0, 0, 0), const Eigen::Quaternion< float > &sensor_orientation=Eigen::Quaternion< float >(1, 0, 0, 0)) |
Internal function which converts the information present in the geometric and color handlers into VTK PolyData+Scalars, constructs a vtkActor object, and adds all the required information to the internal cloud_actor_map_ object. | |
template<typename PointT > | |
bool | fromHandlersToScreen (const GeometryHandlerConstPtr &geometry_handler, const PointCloudColorHandler< PointT > &color_handler, const std::string &id, int viewport, const Eigen::Vector4f &sensor_origin=Eigen::Vector4f(0, 0, 0, 0), const Eigen::Quaternion< float > &sensor_orientation=Eigen::Quaternion< float >(1, 0, 0, 0)) |
Internal function which converts the information present in the geometric and color handlers into VTK PolyData+Scalars, constructs a vtkActor object, and adds all the required information to the internal cloud_actor_map_ object. | |
void | getTransformationMatrix (const Eigen::Vector4f &origin, const Eigen::Quaternion< float > &orientation, Eigen::Matrix4f &transformation) |
Transform the point cloud viewpoint to a transformation matrix. | |
bool | removeActorFromRenderer (const vtkSmartPointer< vtkLODActor > &actor, int viewport=0) |
Internal method. Removes a vtk actor from the screen. | |
bool | removeActorFromRenderer (const vtkSmartPointer< vtkActor > &actor, int viewport=0) |
Internal method. Removes a vtk actor from the screen. | |
bool | removeActorFromRenderer (const vtkSmartPointer< vtkProp > &actor, int viewport=0) |
Internal method. Adds a vtk actor to screen. | |
void | updateCells (vtkSmartPointer< vtkIdTypeArray > &cells, vtkSmartPointer< vtkIdTypeArray > &initcells, vtkIdType nr_points) |
Updates a set of cells (vtkIdTypeArray) if the number of points in a cloud changes. | |
Private Attributes | |
vtkSmartPointer < vtkOrientationMarkerWidget > | axes_widget_ |
Internal pointer to widget which contains a set of axes. | |
bool | camera_set_ |
Boolean that holds whether or not the camera parameters were manually initialized. | |
CloudActorMapPtr | cloud_actor_map_ |
Internal list with actor pointers and name IDs for point clouds. | |
CoordinateActorMap | coordinate_actor_map_ |
Internal list with actor pointers and viewpoint for coordinates. | |
vtkSmartPointer< ExitCallback > | exit_callback_ |
vtkSmartPointer < ExitMainLoopTimerCallback > | exit_main_loop_timer_callback_ |
Callback object enabling us to leave the main loop, when a timer fires. | |
vtkSmartPointer < vtkRendererCollection > | rens_ |
The collection of renderers used. | |
ShapeActorMapPtr | shape_actor_map_ |
Internal list with actor pointers and name IDs for shapes. | |
bool | stopped_ |
Set to false if the interaction loop is running. | |
vtkSmartPointer < PCLVisualizerInteractorStyle > | style_ |
The render window interactor style. | |
int | timer_id_ |
Global timer ID. Used in destructor only. | |
vtkSmartPointer< FPSCallback > | update_fps_ |
The FPSCallback object for the current visualizer. | |
bool | use_vbos_ |
Boolean that holds whether or not to use the vtkVertexBufferObjectMapper. | |
vtkSmartPointer< vtkRenderWindow > | win_ |
The render window. |
PCL Visualizer main class.
Definition at line 85 of file pcl_visualizer.h.
Definition at line 95 of file pcl_visualizer.h.
Definition at line 97 of file pcl_visualizer.h.
Definition at line 96 of file pcl_visualizer.h.
typedef boost::shared_ptr<const PCLVisualizer> pcl::visualization::PCLVisualizer::ConstPtr |
Definition at line 89 of file pcl_visualizer.h.
typedef PointCloudGeometryHandler<pcl::PCLPointCloud2> pcl::visualization::PCLVisualizer::GeometryHandler |
Definition at line 91 of file pcl_visualizer.h.
Definition at line 93 of file pcl_visualizer.h.
Definition at line 92 of file pcl_visualizer.h.
typedef boost::shared_ptr<PCLVisualizer> pcl::visualization::PCLVisualizer::Ptr |
Definition at line 88 of file pcl_visualizer.h.
pcl::visualization::PCLVisualizer::PCLVisualizer | ( | const std::string & | name = "" , |
const bool | create_interactor = true |
||
) |
PCL Visualizer constructor.
[in] | name | the window name (empty by default) |
[in] | create_interactor | if true (default), create an interactor, false otherwise |
Definition at line 93 of file pcl_visualizer.cpp.
pcl::visualization::PCLVisualizer::PCLVisualizer | ( | int & | argc, |
char ** | argv, | ||
const std::string & | name = "" , |
||
PCLVisualizerInteractorStyle * | style = PCLVisualizerInteractorStyle::New () , |
||
const bool | create_interactor = true |
||
) |
PCL Visualizer constructor.
[in] | argc | |
[in] | argv | |
[in] | name | the window name (empty by default) |
[in] | style | interactor style (defaults to PCLVisualizerInteractorStyle) |
[in] | create_interactor | if true (default), create an interactor, false otherwise |
Definition at line 155 of file pcl_visualizer.cpp.
pcl::visualization::PCLVisualizer::~PCLVisualizer | ( | ) | [virtual] |
PCL Visualizer destructor.
Definition at line 362 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::addActorToRenderer | ( | const vtkSmartPointer< vtkProp > & | actor, |
int | viewport = 0 |
||
) | [private] |
Internal method. Adds a vtk actor to screen.
[in] | actor | a pointer to the vtk actor object |
[in] | viewport | port where the actor should be added to (default: 0/all) |
Definition at line 974 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addArrow | ( | const P1 & | pt1, |
const P2 & | pt2, | ||
double | r, | ||
double | g, | ||
double | b, | ||
const std::string & | id = "arrow" , |
||
int | viewport = 0 |
||
) |
Add a line arrow segment between two points, and display the distance between them.
[in] | pt1 | the first (start) point on the line |
[in] | pt2 | the second (end) point on the line |
[in] | r | the red channel of the color that the line should be rendered with |
[in] | g | the green channel of the color that the line should be rendered with |
[in] | b | the blue channel of the color that the line should be rendered with |
[in] | id | the arrow id/name (default: "arrow") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 455 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addArrow | ( | const P1 & | pt1, |
const P2 & | pt2, | ||
double | r, | ||
double | g, | ||
double | b, | ||
bool | display_length, | ||
const std::string & | id = "arrow" , |
||
int | viewport = 0 |
||
) |
Add a line arrow segment between two points, and display the distance between them.
[in] | pt1 | the first (start) point on the line |
[in] | pt2 | the second (end) point on the line |
[in] | r | the red channel of the color that the line should be rendered with |
[in] | g | the green channel of the color that the line should be rendered with |
[in] | b | the blue channel of the color that the line should be rendered with |
[in] | display_length | true if the length should be displayed on the arrow as text |
[in] | id | the line id/name (default: "arrow") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 484 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addArrow | ( | const P1 & | pt1, |
const P2 & | pt2, | ||
double | r_line, | ||
double | g_line, | ||
double | b_line, | ||
double | r_text, | ||
double | g_text, | ||
double | b_text, | ||
const std::string & | id = "arrow" , |
||
int | viewport = 0 |
||
) |
Add a line arrow segment between two points, and display the distance between them in a given color.
[in] | pt1 | the first (start) point on the line |
[in] | pt2 | the second (end) point on the line |
[in] | r_line | the red channel of the color that the line should be rendered with |
[in] | g_line | the green channel of the color that the line should be rendered with |
[in] | b_line | the blue channel of the color that the line should be rendered with |
[in] | r_text | the red channel of the color that the text should be rendered with |
[in] | g_text | the green channel of the color that the text should be rendered with |
[in] | b_text | the blue channel of the color that the text should be rendered with |
[in] | id | the line id/name (default: "arrow") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 516 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addCircle | ( | const pcl::ModelCoefficients & | coefficients, |
const std::string & | id = "circle" , |
||
int | viewport = 0 |
||
) |
Add a circle from a set of given model coefficients.
[in] | coefficients | the model coefficients (x, y, radius) |
[in] | id | the circle id/name (default: "circle") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
// The following are given (or computed using sample consensus techniques) // See SampleConsensusModelCircle2D for more information // float x, y, radius; pcl::ModelCoefficients circle_coeff; circle_coeff.values.resize (3); // We need 3 values circle_coeff.values[0] = x; circle_coeff.values[1] = y; circle_coeff.values[2] = radius; vtkSmartPointer<vtkDataSet> data = pcl::visualization::create2DCircle (circle_coeff, z);
Definition at line 2442 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addCone | ( | const pcl::ModelCoefficients & | coefficients, |
const std::string & | id = "cone" , |
||
int | viewport = 0 |
||
) |
Add a cone from a set of given model coefficients.
[in] | coefficients | the model coefficients (point_on_axis, axis_direction, radiu) |
[in] | id | the cone id/name (default: "cone") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 2468 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::addCoordinateSystem | ( | double | scale = 1.0 , |
int | viewport = 0 |
||
) |
Adds 3D axes describing a coordinate system to screen at 0,0,0.
[in] | scale | the scale of the axes (default: 1) |
[in] | viewport | the view port where the 3D axes should be added (default: all) |
Definition at line 495 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::addCoordinateSystem | ( | double | scale, |
float | x, | ||
float | y, | ||
float | z, | ||
int | viewport = 0 |
||
) |
Adds 3D axes describing a coordinate system to screen at x, y, z.
[in] | scale | the scale of the axes (default: 1) |
[in] | x | the X position of the axes |
[in] | y | the Y position of the axes |
[in] | z | the Z position of the axes |
[in] | viewport | the view port where the 3D axes should be added (default: all) |
Definition at line 534 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::addCoordinateSystem | ( | double | scale, |
const Eigen::Affine3f & | t, | ||
int | viewport = 0 |
||
) |
Adds 3D axes describing a coordinate system to screen at x, y, z, Roll,Pitch,Yaw.
[in] | scale | the scale of the axes (default: 1) |
[in] | t | transformation matrix |
[in] | viewport | the view port where the 3D axes should be added (default: all) |
RPY Angles Rotate the reference frame by the angle roll about axis x Rotate the reference frame by the angle pitch about axis y Rotate the reference frame by the angle yaw about axis z
Description: Sets the orientation of the Prop3D. Orientation is specified as X,Y and Z rotations in that order, but they are performed as RotateZ, RotateX, and finally RotateY.
All axies use right hand rule. x=red axis, y=green axis, z=blue axis z direction is point into the screen. z \ \ \ -----------> x | | | | | | y
Definition at line 604 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addCorrespondences | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | source_points, |
const typename pcl::PointCloud< PointT >::ConstPtr & | target_points, | ||
const std::vector< int > & | correspondences, | ||
const std::string & | id = "correspondences" , |
||
int | viewport = 0 |
||
) |
Add the specified correspondences to the display.
[in] | source_points | The source points |
[in] | target_points | The target points |
[in] | correspondences | The mapping from source points to target points. Each element must be an index into target_points |
[in] | id | the polygon object id (default: "correspondences") |
[in] | viewport | the view port where the correspondences should be added (default: all) |
Definition at line 892 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addCorrespondences | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | source_points, |
const typename pcl::PointCloud< PointT >::ConstPtr & | target_points, | ||
const pcl::Correspondences & | correspondences, | ||
int | nth, | ||
const std::string & | id = "correspondences" , |
||
int | viewport = 0 |
||
) |
Add the specified correspondences to the display.
[in] | source_points | The source points |
[in] | target_points | The target points |
[in] | correspondences | The mapping from source points to target points. Each element must be an index into target_points |
[in] | nth | display only the Nth correspondence (e.g., skip the rest) |
[in] | id | the polygon object id (default: "correspondences") |
[in] | viewport | the view port where the correspondences should be added (default: all) |
Definition at line 990 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addCorrespondences | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | source_points, |
const typename pcl::PointCloud< PointT >::ConstPtr & | target_points, | ||
const pcl::Correspondences & | correspondences, | ||
const std::string & | id = "correspondences" , |
||
int | viewport = 0 |
||
) | [inline] |
Add the specified correspondences to the display.
[in] | source_points | The source points |
[in] | target_points | The target points |
[in] | correspondences | The mapping from source points to target points. Each element must be an index into target_points |
[in] | id | the polygon object id (default: "correspondences") |
[in] | viewport | the view port where the correspondences should be added (default: all) |
Definition at line 929 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::addCube | ( | const pcl::ModelCoefficients & | coefficients, |
const std::string & | id = "cube" , |
||
int | viewport = 0 |
||
) |
Add a cube from a set of given model coefficients.
[in] | coefficients | the model coefficients (Tx, Ty, Tz, Qx, Qy, Qz, Qw, width, height, depth) |
[in] | id | the cube id/name (default: "cube") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 2128 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addCube | ( | const Eigen::Vector3f & | translation, |
const Eigen::Quaternionf & | rotation, | ||
double | width, | ||
double | height, | ||
double | depth, | ||
const std::string & | id = "cube" , |
||
int | viewport = 0 |
||
) |
Add a cube from a set of given model coefficients.
[in] | translation | a translation to apply to the cube from 0,0,0 |
[in] | rotation | a quaternion-based rotation to apply to the cube |
[in] | width | the cube's width |
[in] | height | the cube's height |
[in] | depth | the cube's depth |
[in] | id | the cube id/name (default: "cube") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 2155 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addCube | ( | float | x_min, |
float | x_max, | ||
float | y_min, | ||
float | y_max, | ||
float | z_min, | ||
float | z_max, | ||
double | r = 1.0 , |
||
double | g = 1.0 , |
||
double | b = 1.0 , |
||
const std::string & | id = "cube" , |
||
int | viewport = 0 |
||
) |
Add a cube.
[in] | x_min | the min X coordinate |
[in] | x_max | the max X coordinate |
[in] | y_min | the min Y coordinate |
[in] | y_max | the max Y coordinate |
[in] | z_min | the min Z coordinate |
[in] | z_max | the max Z coordinate |
[in] | r | how much red (0.0 -> 1.0) |
[in] | g | how much green (0.0 -> 1.0) |
[in] | b | how much blue (0.0 -> 1.0) |
[in] | id | the cube id/name (default: "cube") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 2184 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addCylinder | ( | const pcl::ModelCoefficients & | coefficients, |
const std::string & | id = "cylinder" , |
||
int | viewport = 0 |
||
) |
Add a cylinder from a set of given model coefficients.
[in] | coefficients | the model coefficients (point_on_axis, axis_direction, radius) |
[in] | id | the cylinder id/name (default: "cylinder") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
// The following are given (or computed using sample consensus techniques) // See SampleConsensusModelCylinder for more information. // Eigen::Vector3f pt_on_axis, axis_direction; // float radius; pcl::ModelCoefficients cylinder_coeff; cylinder_coeff.values.resize (7); // We need 7 values cylinder_coeff.values[0] = pt_on_axis.x (); cylinder_coeff.values[1] = pt_on_axis.y (); cylinder_coeff.values[2] = pt_on_axis.z (); cylinder_coeff.values[3] = axis_direction.x (); cylinder_coeff.values[4] = axis_direction.y (); cylinder_coeff.values[5] = axis_direction.z (); cylinder_coeff.values[6] = radius; addCylinder (cylinder_coeff);
Definition at line 2101 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addLine | ( | const P1 & | pt1, |
const P2 & | pt2, | ||
const std::string & | id = "line" , |
||
int | viewport = 0 |
||
) |
Add a line segment from two points.
[in] | pt1 | the first (start) point on the line |
[in] | pt2 | the second (end) point on the line |
[in] | id | the line id/name (default: "line") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 550 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addLine | ( | const P1 & | pt1, |
const P2 & | pt2, | ||
double | r, | ||
double | g, | ||
double | b, | ||
const std::string & | id = "line" , |
||
int | viewport = 0 |
||
) |
Add a line segment from two points.
[in] | pt1 | the first (start) point on the line |
[in] | pt2 | the second (end) point on the line |
[in] | r | the red channel of the color that the line should be rendered with |
[in] | g | the green channel of the color that the line should be rendered with |
[in] | b | the blue channel of the color that the line should be rendered with |
[in] | id | the line id/name (default: "line") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 428 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addLine | ( | const pcl::ModelCoefficients & | coefficients, |
const std::string & | id = "line" , |
||
int | viewport = 0 |
||
) |
Add a line from a set of given model coefficients.
[in] | coefficients | the model coefficients (point_on_line, direction) |
[in] | id | the line id/name (default: "line") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
// The following are given (or computed using sample consensus techniques) // See SampleConsensusModelLine for more information // Eigen::Vector3f point_on_line, line_direction; pcl::ModelCoefficients line_coeff; line_coeff.values.resize (6); // We need 6 values line_coeff.values[0] = point_on_line.x (); line_coeff.values[1] = point_on_line.y (); line_coeff.values[2] = point_on_line.z (); line_coeff.values[3] = line_direction.x (); line_coeff.values[4] = line_direction.y (); line_coeff.values[5] = line_direction.z (); addLine (line_coeff);
Definition at line 2359 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addModelFromPLYFile | ( | const std::string & | filename, |
const std::string & | id = "PLYModel" , |
||
int | viewport = 0 |
||
) |
Add a PLYmodel as a mesh.
[in] | filename | of the ply file |
[in] | id | the model id/name (default: "PLYModel") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 2297 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addModelFromPLYFile | ( | const std::string & | filename, |
vtkSmartPointer< vtkTransform > | transform, | ||
const std::string & | id = "PLYModel" , |
||
int | viewport = 0 |
||
) |
Add a PLYmodel as a mesh and applies given transformation.
[in] | filename | of the ply file |
[in] | transform | transformation to apply |
[in] | id | the model id/name (default: "PLYModel") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 2325 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addModelFromPolyData | ( | vtkSmartPointer< vtkPolyData > | polydata, |
const std::string & | id = "PolyData" , |
||
int | viewport = 0 |
||
) |
Add a vtkPolydata as a mesh.
[in] | polydata | vtkPolyData |
[in] | id | the model id/name (default: "PolyData") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 2242 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addModelFromPolyData | ( | vtkSmartPointer< vtkPolyData > | polydata, |
vtkSmartPointer< vtkTransform > | transform, | ||
const std::string & | id = "PolyData" , |
||
int | viewport = 0 |
||
) |
Add a vtkPolydata as a mesh.
[in] | polydata | vtkPolyData |
[in] | transform | transformation to apply |
[in] | id | the model id/name (default: "PolyData") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 2266 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::addOrientationMarkerWidgetAxes | ( | vtkRenderWindowInteractor * | interactor | ) |
Adds a widget which shows an interactive axes display for orientation.
[in] | interactor | - Pointer to the vtk interactor object used by the PCLVisualizer window |
Definition at line 454 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addPlane | ( | const pcl::ModelCoefficients & | coefficients, |
const std::string & | id = "plane" , |
||
int | viewport = 0 |
||
) |
Add a plane from a set of given model coefficients.
[in] | coefficients | the model coefficients (a, b, c, d with ax+by+cz+d=0) |
[in] | id | the plane id/name (default: "plane") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
// The following are given (or computed using sample consensus techniques) // See SampleConsensusModelPlane for more information // Eigen::Vector4f plane_parameters; pcl::ModelCoefficients plane_coeff; plane_coeff.values.resize (4); // We need 4 values plane_coeff.values[0] = plane_parameters.x (); plane_coeff.values[1] = plane_parameters.y (); plane_coeff.values[2] = plane_parameters.z (); plane_coeff.values[3] = plane_parameters.w (); addPlane (plane_coeff);
coefficients | the model coefficients (a, b, c, d with ax+by+cz+d=0) |
id | the plane id/name (default: "plane") |
viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 2390 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addPlane | ( | const pcl::ModelCoefficients & | coefficients, |
double | x, | ||
double | y, | ||
double | z, | ||
const std::string & | id = "plane" , |
||
int | viewport = 0 |
||
) |
Definition at line 2416 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add a Point Cloud (templated) to screen.
[in] | cloud | the input point cloud dataset |
[in] | id | the point cloud object id (default: cloud) |
viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 66 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const PointCloudGeometryHandler< PointT > & | geometry_handler, | ||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add a Point Cloud (templated) to screen.
[in] | cloud | the input point cloud dataset |
[in] | geometry_handler | use a geometry handler object to extract the XYZ data |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 77 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const GeometryHandlerConstPtr & | geometry_handler, | ||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add a Point Cloud (templated) to screen.
Because the geometry handler is given as a pointer, it will be pushed back to the list of available handlers, rather than replacing the current active geometric handler. This makes it possible to switch between different geometric handlers 'on-the-fly' at runtime, from the PCLVisualizer interactor interface (using Alt+0..9).
[in] | cloud | the input point cloud dataset |
[in] | geometry_handler | use a geometry handler object to extract the XYZ data |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 98 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const PointCloudColorHandler< PointT > & | color_handler, | ||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add a Point Cloud (templated) to screen.
[in] | cloud | the input point cloud dataset |
[in] | color_handler | a specific PointCloud visualizer handler for colors |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 121 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const ColorHandlerConstPtr & | color_handler, | ||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add a Point Cloud (templated) to screen.
Because the color handler is given as a pointer, it will be pushed back to the list of available handlers, rather than replacing the current active color handler. This makes it possible to switch between different color handlers 'on-the-fly' at runtime, from the PCLVisualizer interactor interface (using 0..9).
[in] | cloud | the input point cloud dataset |
[in] | color_handler | a specific PointCloud visualizer handler for colors |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 146 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const GeometryHandlerConstPtr & | geometry_handler, | ||
const ColorHandlerConstPtr & | color_handler, | ||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add a Point Cloud (templated) to screen.
Because the geometry/color handler is given as a pointer, it will be pushed back to the list of available handlers, rather than replacing the current active handler. This makes it possible to switch between different handlers 'on-the-fly' at runtime, from the PCLVisualizer interactor interface (using [Alt+]0..9).
[in] | cloud | the input point cloud dataset |
[in] | geometry_handler | a specific PointCloud visualizer handler for geometry |
[in] | color_handler | a specific PointCloud visualizer handler for colors |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 167 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const pcl::PCLPointCloud2::ConstPtr & | cloud, |
const GeometryHandlerConstPtr & | geometry_handler, | ||
const ColorHandlerConstPtr & | color_handler, | ||
const Eigen::Vector4f & | sensor_origin, | ||
const Eigen::Quaternion< float > & | sensor_orientation, | ||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add a binary blob Point Cloud to screen.
Because the geometry/color handler is given as a pointer, it will be pushed back to the list of available handlers, rather than replacing the current active handler. This makes it possible to switch between different handlers 'on-the-fly' at runtime, from the PCLVisualizer interactor interface (using [Alt+]0..9).
[in] | cloud | the input point cloud dataset |
[in] | geometry_handler | a specific PointCloud visualizer handler for geometry |
[in] | color_handler | a specific PointCloud visualizer handler for colors |
[in] | sensor_origin | the origin of the cloud data in global coordinates (defaults to 0,0,0) |
[in] | sensor_orientation | the orientation of the cloud data in global coordinates (defaults to 1,0,0,0) |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 3842 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const pcl::PCLPointCloud2::ConstPtr & | cloud, |
const GeometryHandlerConstPtr & | geometry_handler, | ||
const Eigen::Vector4f & | sensor_origin, | ||
const Eigen::Quaternion< float > & | sensor_orientation, | ||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add a binary blob Point Cloud to screen.
Because the geometry/color handler is given as a pointer, it will be pushed back to the list of available handlers, rather than replacing the current active handler. This makes it possible to switch between different handlers 'on-the-fly' at runtime, from the PCLVisualizer interactor interface (using [Alt+]0..9).
[in] | cloud | the input point cloud dataset |
[in] | geometry_handler | a specific PointCloud visualizer handler for geometry |
[in] | sensor_origin | the origin of the cloud data in global coordinates (defaults to 0,0,0) |
[in] | sensor_orientation | the orientation of the cloud data in global coordinates (defaults to 1,0,0,0) |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 3865 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const pcl::PCLPointCloud2::ConstPtr & | cloud, |
const ColorHandlerConstPtr & | color_handler, | ||
const Eigen::Vector4f & | sensor_origin, | ||
const Eigen::Quaternion< float > & | sensor_orientation, | ||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add a binary blob Point Cloud to screen.
Because the geometry/color handler is given as a pointer, it will be pushed back to the list of available handlers, rather than replacing the current active handler. This makes it possible to switch between different handlers 'on-the-fly' at runtime, from the PCLVisualizer interactor interface (using [Alt+]0..9).
[in] | cloud | the input point cloud dataset |
[in] | color_handler | a specific PointCloud visualizer handler for colors |
[in] | sensor_origin | the origin of the cloud data in global coordinates (defaults to 0,0,0) |
[in] | sensor_orientation | the orientation of the cloud data in global coordinates (defaults to 1,0,0,0) |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 3889 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const PointCloudColorHandler< PointT > & | color_handler, | ||
const PointCloudGeometryHandler< PointT > & | geometry_handler, | ||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add a Point Cloud (templated) to screen.
[in] | cloud | the input point cloud dataset |
[in] | color_handler | a specific PointCloud visualizer handler for colors |
[in] | geometry_handler | use a geometry handler object to extract the XYZ data |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 188 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const pcl::PointCloud< pcl::PointXYZ >::ConstPtr & | cloud, |
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) | [inline] |
Add a PointXYZ Point Cloud to screen.
[in] | cloud | the input point cloud dataset |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 768 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const pcl::PointCloud< pcl::PointXYZRGB >::ConstPtr & | cloud, |
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) | [inline] |
Add a PointXYZRGB Point Cloud to screen.
[in] | cloud | the input point cloud dataset |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 781 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::addPointCloud | ( | const pcl::PointCloud< pcl::PointXYZRGBA >::ConstPtr & | cloud, |
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) | [inline] |
Add a PointXYZRGBA Point Cloud to screen.
[in] | cloud | the input point cloud dataset |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 794 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::addPointCloudIntensityGradients | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const typename pcl::PointCloud< GradientT >::ConstPtr & | gradients, | ||
int | level = 100 , |
||
double | scale = 1e-6 , |
||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add the estimated surface intensity gradients of a Point Cloud to screen.
[in] | cloud | the input point cloud dataset containing the XYZ data |
[in] | gradients | the input point cloud dataset containing the intensity gradient data |
[in] | level | display only every level'th point (default: 100) |
[in] | scale | the intensity gradient arrow scale (default: 1e-6m) |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 817 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPointCloudNormals | ( | const typename pcl::PointCloud< PointNT >::ConstPtr & | cloud, |
int | level = 100 , |
||
float | scale = 0.02f , |
||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add the estimated surface normals of a Point Cloud to screen.
[in] | cloud | the input point cloud dataset containing XYZ data and normals |
[in] | level | display only every level'th point (default: 100) |
[in] | scale | the normal arrow scale (default: 0.02m) |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 696 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPointCloudNormals | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const typename pcl::PointCloud< PointNT >::ConstPtr & | normals, | ||
int | level = 100 , |
||
float | scale = 0.02f , |
||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add the estimated surface normals of a Point Cloud to screen.
[in] | cloud | the input point cloud dataset containing the XYZ data |
[in] | normals | the input point cloud dataset containing the normal data |
[in] | level | display only every level'th point (default: 100) |
[in] | scale | the normal arrow scale (default: 0.02m) |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 705 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPointCloudPrincipalCurvatures | ( | const pcl::PointCloud< pcl::PointXYZ >::ConstPtr & | cloud, |
const pcl::PointCloud< pcl::Normal >::ConstPtr & | normals, | ||
const pcl::PointCloud< pcl::PrincipalCurvatures >::ConstPtr & | pcs, | ||
int | level = 100 , |
||
float | scale = 1.0f , |
||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Add the estimated principal curvatures of a Point Cloud to screen.
[in] | cloud | the input point cloud dataset containing the XYZ data |
[in] | normals | the input point cloud dataset containing the normal data |
[in] | pcs | the input point cloud dataset containing the principal curvatures data |
[in] | level | display only every level'th point. Default: 100 |
[in] | scale | the normal arrow scale. Default: 1.0 |
[in] | id | the point cloud object id. Default: "cloud" |
[in] | viewport | the view port where the Point Cloud should be added (default: all) |
Definition at line 791 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addPolygon | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
double | r, | ||
double | g, | ||
double | b, | ||
const std::string & | id = "polygon" , |
||
int | viewport = 0 |
||
) |
Add a polygon (polyline) that represents the input point cloud (connects all points in order)
[in] | cloud | the point cloud dataset representing the polygon |
[in] | r | the red channel of the color that the polygon should be rendered with |
[in] | g | the green channel of the color that the polygon should be rendered with |
[in] | b | the blue channel of the color that the polygon should be rendered with |
[in] | id | (optional) the polygon id/name (default: "polygon") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 310 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPolygon | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const std::string & | id = "polygon" , |
||
int | viewport = 0 |
||
) |
Add a polygon (polyline) that represents the input point cloud (connects all points in order)
[in] | cloud | the point cloud dataset representing the polygon |
[in] | id | the polygon id/name (default: "polygon") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 419 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPolygon | ( | const pcl::PlanarPolygon< PointT > & | polygon, |
double | r, | ||
double | g, | ||
double | b, | ||
const std::string & | id = "polygon" , |
||
int | viewport = 0 |
||
) |
Add a planar polygon that represents the input point cloud (connects all points in order)
[in] | polygon | the polygon to draw |
[in] | r | the red channel of the color that the polygon should be rendered with |
[in] | g | the green channel of the color that the polygon should be rendered with |
[in] | b | the blue channel of the color that the polygon should be rendered with |
[in] | id | the polygon id/name (default: "polygon") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 364 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPolygonMesh | ( | const pcl::PolygonMesh & | polymesh, |
const std::string & | id = "polygon" , |
||
int | viewport = 0 |
||
) |
Add a PolygonMesh object to screen.
[in] | polymesh | the polygonal mesh |
[in] | id | the polygon object id (default: "polygon") |
[in] | viewport | the view port where the PolygonMesh should be added (default: all) |
Definition at line 2790 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addPolygonMesh | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const std::vector< pcl::Vertices > & | vertices, | ||
const std::string & | id = "polygon" , |
||
int | viewport = 0 |
||
) |
Add a PolygonMesh object to screen.
[in] | cloud | the polygonal mesh point cloud |
[in] | vertices | the polygonal mesh vertices |
[in] | id | the polygon object id (default: "polygon") |
[in] | viewport | the view port where the PolygonMesh should be added (default: all) |
Definition at line 1522 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addPolylineFromPolygonMesh | ( | const pcl::PolygonMesh & | polymesh, |
const std::string & | id = "polyline" , |
||
int | viewport = 0 |
||
) |
Add a Polygonline from a polygonMesh object to screen.
[in] | polymesh | the polygonal mesh from where the polylines will be extracted |
[in] | id | the polygon object id (default: "polygon") |
[in] | viewport | the view port where the PolygonMesh should be added (default: all) |
Definition at line 3012 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addSphere | ( | const PointT & | center, |
double | radius, | ||
const std::string & | id = "sphere" , |
||
int | viewport = 0 |
||
) |
Add a sphere shape from a point and a radius.
[in] | center | the center of the sphere |
[in] | radius | the radius of the sphere |
[in] | id | the sphere id/name (default: "sphere") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 599 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addSphere | ( | const PointT & | center, |
double | radius, | ||
double | r, | ||
double | g, | ||
double | b, | ||
const std::string & | id = "sphere" , |
||
int | viewport = 0 |
||
) |
Add a sphere shape from a point and a radius.
[in] | center | the center of the sphere |
[in] | radius | the radius of the sphere |
[in] | r | the red channel of the color that the sphere should be rendered with |
[in] | g | the green channel of the color that the sphere should be rendered with |
[in] | b | the blue channel of the color that the sphere should be rendered with |
[in] | id | the sphere id/name (default: "sphere") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
Definition at line 557 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::addSphere | ( | const pcl::ModelCoefficients & | coefficients, |
const std::string & | id = "sphere" , |
||
int | viewport = 0 |
||
) |
Add a sphere from a set of given model coefficients.
[in] | coefficients | the model coefficients (sphere center, radius) |
[in] | id | the sphere id/name (default: "sphere") |
[in] | viewport | (optional) the id of the new viewport (default: 0) |
// The following are given (or computed using sample consensus techniques) // See SampleConsensusModelSphere for more information // Eigen::Vector3f sphere_center; // float radius; pcl::ModelCoefficients sphere_coeff; sphere_coeff.values.resize (4); // We need 4 values sphere_coeff.values[0] = sphere_center.x (); sphere_coeff.values[1] = sphere_center.y (); sphere_coeff.values[2] = sphere_center.z (); sphere_coeff.values[3] = radius; addSphere (sphere_coeff);
Definition at line 2215 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addText | ( | const std::string & | text, |
int | xpos, | ||
int | ypos, | ||
const std::string & | id = "" , |
||
int | viewport = 0 |
||
) |
Add a text to screen.
[in] | text | the text to add |
[in] | xpos | the X position on screen where the text should be added |
[in] | ypos | the Y position on screen where the text should be added |
[in] | id | the text object id (default: equal to the "text" parameter) |
[in] | viewport | the view port (default: all) |
Definition at line 2539 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addText | ( | const std::string & | text, |
int | xpos, | ||
int | ypos, | ||
double | r, | ||
double | g, | ||
double | b, | ||
const std::string & | id = "" , |
||
int | viewport = 0 |
||
) |
Add a text to screen.
[in] | text | the text to add |
[in] | xpos | the X position on screen where the text should be added |
[in] | ypos | the Y position on screen where the text should be added |
[in] | r | the red color value |
[in] | g | the green color value |
[in] | b | the blue color vlaue |
[in] | id | the text object id (default: equal to the "text" parameter) |
[in] | viewport | the view port (default: all) |
Definition at line 2575 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addText | ( | const std::string & | text, |
int | xpos, | ||
int | ypos, | ||
int | fontsize, | ||
double | r, | ||
double | g, | ||
double | b, | ||
const std::string & | id = "" , |
||
int | viewport = 0 |
||
) |
Add a text to screen.
[in] | text | the text to add |
[in] | xpos | the X position on screen where the text should be added |
[in] | ypos | the Y position on screen where the text should be added |
[in] | fontsize | the fontsize of the text |
[in] | r | the red color value |
[in] | g | the green color value |
[in] | b | the blue color vlaue |
[in] | id | the text object id (default: equal to the "text" parameter) |
[in] | viewport | the view port (default: all) |
Definition at line 2611 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::addText3D | ( | const std::string & | text, |
const PointT & | position, | ||
double | textScale = 1.0 , |
||
double | r = 1.0 , |
||
double | g = 1.0 , |
||
double | b = 1.0 , |
||
const std::string & | id = "" , |
||
int | viewport = 0 |
||
) |
Add a 3d text to the scene.
[in] | text | the text to add |
[in] | position | the world position where the text should be added |
[in] | textScale | the scale of the text to render |
[in] | r | the red color value |
[in] | g | the green color value |
[in] | b | the blue color value |
[in] | id | the text object id (default: equal to the "text" parameter) |
[in] | viewport | the view port (default: all) |
Definition at line 630 of file pcl_visualizer.hpp.
void pcl::visualization::PCLVisualizer::allocVtkPolyData | ( | vtkSmartPointer< vtkAppendPolyData > & | polydata | ) | [private] |
Allocate a new polydata smartpointer. Internal.
[out] | polydata | the resultant poly data |
Definition at line 3769 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::allocVtkPolyData | ( | vtkSmartPointer< vtkPolyData > & | polydata | ) | [private] |
Allocate a new polydata smartpointer. Internal.
[out] | polydata | the resultant poly data |
Definition at line 3775 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::allocVtkUnstructuredGrid | ( | vtkSmartPointer< vtkUnstructuredGrid > & | polydata | ) | [private] |
Allocate a new unstructured grid smartpointer. Internal.
[out] | polydata | the resultant poly data |
Definition at line 3781 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::cameraParamsSet | ( | ) | const |
Checks whether the camera parameters were manually loaded from file.
Definition at line 1620 of file pcl_visualizer.cpp.
Stop the interaction and close the visualizaton window.
Definition at line 3952 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::convertPointCloudToVTKPolyData | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
vtkSmartPointer< vtkPolyData > & | polydata, | ||
vtkSmartPointer< vtkIdTypeArray > & | initcells | ||
) | [private] |
Converts a PCL templated PointCloud object to a vtk polydata object.
[in] | cloud | the input PCL PointCloud dataset |
[out] | polydata | the resultant polydata containing the cloud |
[out] | initcells | a list of cell indices used for the conversion. This can be set once and then passed around to speed up the conversion. |
Definition at line 212 of file pcl_visualizer.hpp.
void pcl::visualization::PCLVisualizer::convertPointCloudToVTKPolyData | ( | const PointCloudGeometryHandler< PointT > & | geometry_handler, |
vtkSmartPointer< vtkPolyData > & | polydata, | ||
vtkSmartPointer< vtkIdTypeArray > & | initcells | ||
) | [private] |
Converts a PCL templated PointCloud object to a vtk polydata object.
[in] | geometry_handler | the geometry handler object used to extract the XYZ data |
[out] | polydata | the resultant polydata containing the cloud |
[out] | initcells | a list of cell indices used for the conversion. This can be set once and then passed around to speed up the conversion. |
Definition at line 277 of file pcl_visualizer.hpp.
void pcl::visualization::PCLVisualizer::convertPointCloudToVTKPolyData | ( | const GeometryHandlerConstPtr & | geometry_handler, |
vtkSmartPointer< vtkPolyData > & | polydata, | ||
vtkSmartPointer< vtkIdTypeArray > & | initcells | ||
) | [private] |
Converts a PCL templated PointCloud object to a vtk polydata object.
[in] | geometry_handler | the geometry handler object used to extract the XYZ data |
[out] | polydata | the resultant polydata containing the cloud |
[out] | initcells | a list of cell indices used for the conversion. This can be set once and then passed around to speed up the conversion. |
Definition at line 1206 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::convertToEigenMatrix | ( | const vtkSmartPointer< vtkMatrix4x4 > & | vtk_matrix, |
Eigen::Matrix4f & | m | ||
) | [static] |
Convert vtkMatrix4x4 to an Eigen4f.
[in] | vtk_matrix | the original VTK 4x4 matrix |
[out] | m | the resultant Eigen 4x4 matrix |
Definition at line 3831 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::convertToVtkMatrix | ( | const Eigen::Matrix4f & | m, |
vtkSmartPointer< vtkMatrix4x4 > & | vtk_matrix | ||
) | [static] |
Convert Eigen::Matrix4f to vtkMatrix4x4.
[in] | m | the input Eigen matrix |
[out] | vtk_matrix | the resultant VTK matrix |
Definition at line 3820 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::convertToVtkMatrix | ( | const Eigen::Vector4f & | origin, |
const Eigen::Quaternion< float > & | orientation, | ||
vtkSmartPointer< vtkMatrix4x4 > & | vtk_matrix | ||
) | [static] |
Convert origin and orientation to vtkMatrix4x4.
[in] | origin | the point cloud origin |
[in] | orientation | the point cloud orientation |
[out] | vtk_matrix | the resultant VTK 4x4 matrix |
Definition at line 3800 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::createActorFromVTKDataSet | ( | const vtkSmartPointer< vtkDataSet > & | data, |
vtkSmartPointer< vtkActor > & | actor, | ||
bool | use_scalars = true |
||
) | [private] |
Internal method. Creates a vtk actor from a vtk polydata object.
[in] | data | the vtk polydata object to create an actor for |
[out] | actor | the resultant vtk actor object |
[in] | use_scalars | set scalar properties to the mapper if it exists in the data. Default: true. |
FIXME disabling backface culling due to known VTK bug: vtkTextActors are not shown when there is a vtkActor with backface culling on present in the scene Please see VTK bug tracker for more details: http://www.vtk.org/Bug/view.php?id=12588
FIXME disabling backface culling due to known VTK bug: vtkTextActors are not shown when there is a vtkActor with backface culling on present in the scene Please see VTK bug tracker for more details: http://www.vtk.org/Bug/view.php?id=12588
Definition at line 1129 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::createActorFromVTKDataSet | ( | const vtkSmartPointer< vtkDataSet > & | data, |
vtkSmartPointer< vtkLODActor > & | actor, | ||
bool | use_scalars = true |
||
) | [private] |
Internal method. Creates a vtk actor from a vtk polydata object.
[in] | data | the vtk polydata object to create an actor for |
[out] | actor | the resultant vtk actor object |
[in] | use_scalars | set scalar properties to the mapper if it exists in the data. Default: true. |
FIXME disabling backface culling due to known VTK bug: vtkTextActors are not shown when there is a vtkActor with backface culling on present in the scene Please see VTK bug tracker for more details: http://www.vtk.org/Bug/view.php?id=12588
FIXME disabling backface culling due to known VTK bug: vtkTextActors are not shown when there is a vtkActor with backface culling on present in the scene Please see VTK bug tracker for more details: http://www.vtk.org/Bug/view.php?id=12588
Definition at line 1055 of file pcl_visualizer.cpp.
Create the internal Interactor object.
Definition at line 226 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::createViewPort | ( | double | xmin, |
double | ymin, | ||
double | xmax, | ||
double | ymax, | ||
int & | viewport | ||
) |
Create a new viewport from [xmin,ymin] -> [xmax,ymax].
[in] | xmin | the minimum X coordinate for the viewport (0.0 <= 1.0) |
[in] | ymin | the minimum Y coordinate for the viewport (0.0 <= 1.0) |
[in] | xmax | the maximum X coordinate for the viewport (0.0 <= 1.0) |
[in] | ymax | the maximum Y coordinate for the viewport (0.0 <= 1.0) |
[in] | viewport | the id of the new viewport |
Definition at line 2494 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::createViewPortCamera | ( | const int | viewport | ) |
Create a new separate camera for the given viewport.
[in] | viewport | the viewport to create a new camera for. |
Definition at line 2518 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::fromHandlersToScreen | ( | const PointCloudGeometryHandler< PointT > & | geometry_handler, |
const PointCloudColorHandler< PointT > & | color_handler, | ||
const std::string & | id, | ||
int | viewport, | ||
const Eigen::Vector4f & | sensor_origin = Eigen::Vector4f (0, 0, 0, 0) , |
||
const Eigen::Quaternion< float > & | sensor_orientation = Eigen::Quaternion<float> (1, 0, 0 ,0) |
||
) | [private] |
Internal function which converts the information present in the geometric and color handlers into VTK PolyData+Scalars, constructs a vtkActor object, and adds all the required information to the internal cloud_actor_map_ object.
[in] | geometry_handler | the geometric handler that contains the XYZ data |
[in] | color_handler | the color handler that contains the "RGB" (scalar) data |
[in] | id | the point cloud object id |
[in] | viewport | the view port where the Point Cloud should be added |
[in] | sensor_origin | the origin of the cloud data in global coordinates (defaults to 0,0,0) |
[in] | sensor_orientation | the orientation of the cloud data in global coordinates (defaults to 1,0,0,0) |
Definition at line 1191 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::fromHandlersToScreen | ( | const PointCloudGeometryHandler< PointT > & | geometry_handler, |
const ColorHandlerConstPtr & | color_handler, | ||
const std::string & | id, | ||
int | viewport, | ||
const Eigen::Vector4f & | sensor_origin = Eigen::Vector4f (0, 0, 0, 0) , |
||
const Eigen::Quaternion< float > & | sensor_orientation = Eigen::Quaternion<float> (1, 0, 0 ,0) |
||
) | [private] |
Internal function which converts the information present in the geometric and color handlers into VTK PolyData+Scalars, constructs a vtkActor object, and adds all the required information to the internal cloud_actor_map_ object.
[in] | geometry_handler | the geometric handler that contains the XYZ data |
[in] | color_handler | the color handler that contains the "RGB" (scalar) data |
[in] | id | the point cloud object id |
[in] | viewport | the view port where the Point Cloud should be added |
[in] | sensor_origin | the origin of the cloud data in global coordinates (defaults to 0,0,0) |
[in] | sensor_orientation | the orientation of the cloud data in global coordinates (defaults to 1,0,0,0) |
Definition at line 1255 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::fromHandlersToScreen | ( | const GeometryHandlerConstPtr & | geometry_handler, |
const ColorHandlerConstPtr & | color_handler, | ||
const std::string & | id, | ||
int | viewport, | ||
const Eigen::Vector4f & | sensor_origin = Eigen::Vector4f (0, 0, 0, 0) , |
||
const Eigen::Quaternion< float > & | sensor_orientation = Eigen::Quaternion<float> (1, 0, 0 ,0) |
||
) | [private] |
Internal function which converts the information present in the geometric and color handlers into VTK PolyData+Scalars, constructs a vtkActor object, and adds all the required information to the internal cloud_actor_map_ object.
[in] | geometry_handler | the geometric handler that contains the XYZ data |
[in] | color_handler | the color handler that contains the "RGB" (scalar) data |
[in] | id | the point cloud object id |
[in] | viewport | the view port where the Point Cloud should be added |
[in] | sensor_origin | the origin of the cloud data in global coordinates (defaults to 0,0,0) |
[in] | sensor_orientation | the orientation of the cloud data in global coordinates (defaults to 1,0,0,0) |
Definition at line 3657 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::fromHandlersToScreen | ( | const GeometryHandlerConstPtr & | geometry_handler, |
const PointCloudColorHandler< PointT > & | color_handler, | ||
const std::string & | id, | ||
int | viewport, | ||
const Eigen::Vector4f & | sensor_origin = Eigen::Vector4f (0, 0, 0, 0) , |
||
const Eigen::Quaternion< float > & | sensor_orientation = Eigen::Quaternion<float> (1, 0, 0 ,0) |
||
) | [private] |
Internal function which converts the information present in the geometric and color handlers into VTK PolyData+Scalars, constructs a vtkActor object, and adds all the required information to the internal cloud_actor_map_ object.
[in] | geometry_handler | the geometric handler that contains the XYZ data |
[in] | color_handler | the color handler that contains the "RGB" (scalar) data |
[in] | id | the point cloud object id |
[in] | viewport | the view port where the Point Cloud should be added |
[in] | sensor_origin | the origin of the cloud data in global coordinates (defaults to 0,0,0) |
[in] | sensor_orientation | the orientation of the cloud data in global coordinates (defaults to 1,0,0,0) |
Definition at line 1320 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::getCameraParameters | ( | int | argc, |
char ** | argv | ||
) |
Search for camera parameters at the command line and set them internally.
[in] | argc | |
[in] | argv |
Definition at line 1970 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::getCameras | ( | std::vector< Camera > & | cameras | ) |
Get the current camera parameters.
Definition at line 1681 of file pcl_visualizer.cpp.
Return a pointer to the CloudActorMap this visualizer uses.
Definition at line 1624 of file pcl_visualizer.h.
int pcl::visualization::PCLVisualizer::getColorHandlerIndex | ( | const std::string & | id | ) |
Get the color handler index of a rendered PointCloud based on its ID.
[in] | id | the point cloud object id |
Definition at line 3976 of file pcl_visualizer.cpp.
int pcl::visualization::PCLVisualizer::getGeometryHandlerIndex | ( | const std::string & | id | ) |
Get the geometry handler index of a rendered PointCloud based on its ID.
[in] | id | the point cloud object id |
Definition at line 3987 of file pcl_visualizer.cpp.
vtkSmartPointer<PCLVisualizerInteractorStyle> pcl::visualization::PCLVisualizer::getInteractorStyle | ( | ) | [inline] |
Get a pointer to the current interactor style used.
Definition at line 1676 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::getPointCloudRenderingProperties | ( | int | property, |
double & | value, | ||
const std::string & | id = "cloud" |
||
) |
Get the rendering properties of a PointCloud.
[in] | property | the property type |
[in] | value | the resultant property value |
[in] | id | the point cloud object id (default: cloud) |
Definition at line 1299 of file pcl_visualizer.cpp.
vtkSmartPointer<vtkRendererCollection> pcl::visualization::PCLVisualizer::getRendererCollection | ( | ) | [inline] |
Return a pointer to the underlying VTK Renderer Collection.
Definition at line 1617 of file pcl_visualizer.h.
vtkSmartPointer<vtkRenderWindow> pcl::visualization::PCLVisualizer::getRenderWindow | ( | ) | [inline] |
Return a pointer to the underlying VTK Render Window used.
Definition at line 1610 of file pcl_visualizer.h.
void pcl::visualization::PCLVisualizer::getTransformationMatrix | ( | const Eigen::Vector4f & | origin, |
const Eigen::Quaternion< float > & | orientation, | ||
Eigen::Matrix4f & | transformation | ||
) | [private] |
Transform the point cloud viewpoint to a transformation matrix.
[in] | origin | the camera origin |
[in] | orientation | the camera orientation |
[out] | transformation | the camera transformation matrix |
Definition at line 3788 of file pcl_visualizer.cpp.
Eigen::Affine3f pcl::visualization::PCLVisualizer::getViewerPose | ( | int | viewport = 0 | ) |
Get the current viewing pose.
TODO replace this ugly thing with matrix.block () = vector3f
Definition at line 1710 of file pcl_visualizer.cpp.
Initialize camera parameters with some default values.
Definition at line 1586 of file pcl_visualizer.cpp.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerAreaPickingCallback | ( | boost::function< void(const pcl::visualization::AreaPickingEvent &)> | cb | ) |
Register a callback function for area picking events.
[in] | cb | a boost function that will be registered as a callback for an area picking event |
Definition at line 411 of file pcl_visualizer.cpp.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerAreaPickingCallback | ( | void(*)(const pcl::visualization::AreaPickingEvent &, void *) | callback, |
void * | cookie = NULL |
||
) |
Register a callback function for area picking events.
[in] | callback | the function that will be registered as a callback for an area picking event |
[in] | cookie | user data that is passed to the callback |
Definition at line 418 of file pcl_visualizer.cpp.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerAreaPickingCallback | ( | void(T::*)(const pcl::visualization::AreaPickingEvent &, void *) | callback, |
T & | instance, | ||
void * | cookie = NULL |
||
) | [inline] |
Register a callback function for area picking events.
[in] | callback | the member function that will be registered as a callback for an area picking event |
[in] | instance | instance to the class that implements the callback function |
[in] | cookie | user data that is passed to the callback |
Definition at line 249 of file pcl_visualizer.h.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerKeyboardCallback | ( | boost::function< void(const pcl::visualization::KeyboardEvent &)> | cb | ) |
Register a callback boost::function for keyboard events.
[in] | cb | a boost function that will be registered as a callback for a keyboard event |
Definition at line 383 of file pcl_visualizer.cpp.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerKeyboardCallback | ( | void(*)(const pcl::visualization::KeyboardEvent &, void *) | callback, |
void * | cookie = NULL |
||
) | [inline] |
Register a callback function for keyboard events.
[in] | callback | the function that will be registered as a callback for a keyboard event |
[in] | cookie | user data that is passed to the callback |
Definition at line 153 of file pcl_visualizer.h.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerKeyboardCallback | ( | void(T::*)(const pcl::visualization::KeyboardEvent &, void *) | callback, |
T & | instance, | ||
void * | cookie = NULL |
||
) | [inline] |
Register a callback function for keyboard events.
[in] | callback | the member function that will be registered as a callback for a keyboard event |
[in] | instance | instance to the class that implements the callback function |
[in] | cookie | user data that is passed to the callback |
Definition at line 165 of file pcl_visualizer.h.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerMouseCallback | ( | boost::function< void(const pcl::visualization::MouseEvent &)> | cb | ) |
Register a callback function for mouse events.
[in] | cb | a boost function that will be registered as a callback for a mouse event |
Definition at line 390 of file pcl_visualizer.cpp.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerMouseCallback | ( | void(*)(const pcl::visualization::MouseEvent &, void *) | callback, |
void * | cookie = NULL |
||
) | [inline] |
Register a callback function for mouse events.
[in] | callback | the function that will be registered as a callback for a mouse event |
[in] | cookie | user data that is passed to the callback |
Definition at line 183 of file pcl_visualizer.h.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerMouseCallback | ( | void(T::*)(const pcl::visualization::MouseEvent &, void *) | callback, |
T & | instance, | ||
void * | cookie = NULL |
||
) | [inline] |
Register a callback function for mouse events.
[in] | callback | the member function that will be registered as a callback for a mouse event |
[in] | instance | instance to the class that implements the callback function |
[in] | cookie | user data that is passed to the callback |
Definition at line 195 of file pcl_visualizer.h.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerPointPickingCallback | ( | boost::function< void(const pcl::visualization::PointPickingEvent &)> | cb | ) |
Register a callback function for point picking events.
[in] | cb | a boost function that will be registered as a callback for a point picking event |
Definition at line 397 of file pcl_visualizer.cpp.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerPointPickingCallback | ( | void(*)(const pcl::visualization::PointPickingEvent &, void *) | callback, |
void * | cookie = NULL |
||
) |
Register a callback function for point picking events.
[in] | callback | the function that will be registered as a callback for a point picking event |
[in] | cookie | user data that is passed to the callback |
Definition at line 404 of file pcl_visualizer.cpp.
boost::signals2::connection pcl::visualization::PCLVisualizer::registerPointPickingCallback | ( | void(T::*)(const pcl::visualization::PointPickingEvent &, void *) | callback, |
T & | instance, | ||
void * | cookie = NULL |
||
) | [inline] |
Register a callback function for point picking events.
[in] | callback | the member function that will be registered as a callback for a point picking event |
[in] | instance | instance to the class that implements the callback function |
[in] | cookie | user data that is passed to the callback |
Definition at line 222 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::removeActorFromRenderer | ( | const vtkSmartPointer< vtkLODActor > & | actor, |
int | viewport = 0 |
||
) | [private] |
Internal method. Removes a vtk actor from the screen.
[in] | actor | a pointer to the vtk actor object |
[in] | viewport | the view port where the actor should be removed from (default: all) |
Definition at line 894 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::removeActorFromRenderer | ( | const vtkSmartPointer< vtkActor > & | actor, |
int | viewport = 0 |
||
) | [private] |
Internal method. Removes a vtk actor from the screen.
[in] | actor | a pointer to the vtk actor object |
[in] | viewport | the view port where the actor should be removed from (default: all) |
Definition at line 934 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::removeActorFromRenderer | ( | const vtkSmartPointer< vtkProp > & | actor, |
int | viewport = 0 |
||
) | [private] |
Internal method. Adds a vtk actor to screen.
[in] | actor | a pointer to the vtk actor object |
[in] | viewport | the view port where the actor should be added to (default: all) |
Definition at line 999 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::removeAllPointClouds | ( | int | viewport = 0 | ) |
Remove all point cloud data on screen from the given viewport.
[in] | viewport | view port from where the clouds should be removed (default: all) |
Definition at line 759 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::removeAllShapes | ( | int | viewport = 0 | ) |
Remove all 3D shape data on screen from the given viewport.
[in] | viewport | view port from where the shapes should be removed (default: all) |
Definition at line 775 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::removeCoordinateSystem | ( | int | viewport = 0 | ) |
Removes a previously added 3D axes (coordinate system)
[in] | viewport | view port where the 3D axes should be removed from (default: all) |
Definition at line 656 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::removeCorrespondences | ( | const std::string & | id = "correspondences" , |
int | viewport = 0 |
||
) |
Remove the specified correspondences from the display.
[in] | id | the polygon correspondences object id (i.e., given on addCorrespondences) |
[in] | viewport | view port from where the correspondences should be removed (default: all) |
Definition at line 3968 of file pcl_visualizer.cpp.
Disables the Orientatation Marker Widget so it is removed from the renderer.
Definition at line 478 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::removePointCloud | ( | const std::string & | id = "cloud" , |
int | viewport = 0 |
||
) |
Removes a Point Cloud from screen, based on a given ID.
[in] | id | the point cloud object id (i.e., given on addPointCloud) |
[in] | viewport | view port from where the Point Cloud should be removed (default: all) |
Definition at line 676 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::removePolygonMesh | ( | const std::string & | id = "polygon" , |
int | viewport = 0 |
||
) | [inline] |
Removes a PolygonMesh from screen, based on a given ID.
[in] | id | the polygon object id (i.e., given on addPolygonMesh) |
[in] | viewport | view port from where the PolygonMesh should be removed (default: all) |
Definition at line 347 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::removeShape | ( | const std::string & | id = "cloud" , |
int | viewport = 0 |
||
) |
Removes an added shape from screen (line, polygon, etc.), based on a given ID.
[in] | id | the shape object id (i.e., given on addLine etc.) |
[in] | viewport | view port from where the Point Cloud should be removed (default: all) |
Definition at line 696 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::removeText3D | ( | const std::string & | id = "cloud" , |
int | viewport = 0 |
||
) |
Removes an added 3D text from the scene, based on a given ID.
[in] | id | the 3D text id (i.e., given on addText3D etc.) |
[in] | viewport | view port from where the 3D text should be removed (default: all) |
Definition at line 736 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::renderView | ( | int | xres, |
int | yres, | ||
pcl::PointCloud< pcl::PointXYZ >::Ptr & | cloud | ||
) |
Renders a virtual scene as seen from the camera viewpoint and returns the rendered point cloud. ATT: This method will only render the scene if only on viewport exists. Otherwise, returns an empty point cloud and exits immediately.
[in] | xres | is the size of the window (X) used to render the scene |
[in] | yres | is the size of the window (Y) used to render the scene |
[in] | cloud | is the rendered point cloud |
Definition at line 3583 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::renderViewTesselatedSphere | ( | int | xres, |
int | yres, | ||
pcl::PointCloud< pcl::PointXYZ >::CloudVectorType & | cloud, | ||
std::vector< Eigen::Matrix4f, Eigen::aligned_allocator< Eigen::Matrix4f > > & | poses, | ||
std::vector< float > & | enthropies, | ||
int | tesselation_level, | ||
float | view_angle = 45 , |
||
float | radius_sphere = 1 , |
||
bool | use_vertices = true |
||
) |
The purpose of this method is to render a CAD model added to the visualizer from different viewpoints in order to simulate partial views of model. The viewpoint locations are the vertices of a tesselated sphere build from an icosaheadron. The tesselation paremeter controls how many times the triangles of the original icosahedron are divided to approximate the sphere and thus the number of partial view generated for a model, with a tesselation_level of 0, 12 views are generated if use_vertices=true and 20 views if use_vertices=false.
[in] | xres | the size of the window (X) used to render the partial view of the object |
[in] | yres | the size of the window (Y) used to render the partial view of the object |
[in] | cloud | is a vector of pointcloud with XYZ information that represent the model as seen from the respective viewpoints. |
[out] | poses | represent the transformation from object coordinates to camera coordinates for the respective viewpoint. |
[out] | enthropies | are values between 0 and 1 representing which percentage of the model is seen from the respective viewpoint. |
[in] | tesselation_level | represents the number of subdivisions applied to the triangles of original icosahedron. |
[in] | view_angle | field of view of the virtual camera. Default: 45 |
[in] | radius_sphere | the tesselated sphere radius. Default: 1 |
[in] | use_vertices | if true, use the vertices of tesselated icosahedron (12,42,...) or if false, use the faces of tesselated icosahedron (20,80,...). Default: true |
Definition at line 3141 of file pcl_visualizer.cpp.
Reset camera parameters and render.
Definition at line 1758 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::resetCameraViewpoint | ( | const std::string & | id = "cloud" | ) |
Reset the camera direction from {0, 0, 0} to the center_{x, y, z} of a given dataset.
[in] | id | the point cloud object id (default: cloud) |
Definition at line 1931 of file pcl_visualizer.cpp.
Set the stopped flag back to false.
Definition at line 4012 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::saveScreenshot | ( | const std::string & | file | ) |
Save the current rendered image to disk, as a PNG screenshot.
[in] | file | the name of the PNG file |
Definition at line 376 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setBackgroundColor | ( | const double & | r, |
const double & | g, | ||
const double & | b, | ||
int | viewport = 0 |
||
) |
Set the viewport's background color.
[in] | r | the red component of the RGB color |
[in] | g | the green component of the RGB color |
[in] | b | the blue component of the RGB color |
[in] | viewport | the view port (default: all) |
Definition at line 1240 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setCameraClipDistances | ( | double | near, |
double | far, | ||
int | viewport = 0 |
||
) |
Set the camera clipping distances.
[in] | near | the near clipping distance (no objects closer than this to the camera will be drawn) |
[in] | far | the far clipping distance (no objects further away than this to the camera will be drawn) |
Definition at line 1894 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setCameraFieldOfView | ( | double | fovy, |
int | viewport = 0 |
||
) |
Set the camera vertical field of view.
[in] | fovy | vertical field of view in radians |
[in] | viewport | the viewport to modify camera of (0 modifies all cameras) |
Definition at line 1912 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setCameraParameters | ( | const Eigen::Matrix3f & | intrinsics, |
const Eigen::Matrix4f & | extrinsics, | ||
int | viewport = 0 |
||
) |
Set the camera parameters via an intrinsics and and extrinsics matrix.
[in] | intrinsics | the intrinsics that will be used to compute the VTK camera parameters |
[in] | extrinsics | the extrinsics that will be used to compute the VTK camera parameters |
[in] | viewport | the viewport to modify camera of (0 modifies all cameras) |
Definition at line 1819 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setCameraParameters | ( | const Camera & | camera, |
int | viewport = 0 |
||
) |
Set the camera parameters by given a full camera data structure.
[in] | camera | camera structure containing all the camera parameters. |
[in] | viewport | the viewport to modify camera of (0 modifies all cameras) |
Definition at line 1868 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setCameraPosition | ( | double | pos_x, |
double | pos_y, | ||
double | pos_z, | ||
double | view_x, | ||
double | view_y, | ||
double | view_z, | ||
double | up_x, | ||
double | up_y, | ||
double | up_z, | ||
int | viewport = 0 |
||
) |
Set the camera pose given by position, viewpoint and up vector.
[in] | pos_x | the x coordinate of the camera location |
[in] | pos_y | the y coordinate of the camera location |
[in] | pos_z | the z coordinate of the camera location |
[in] | view_x | the x component of the view point of the camera |
[in] | view_y | the y component of the view point of the camera |
[in] | view_z | the z component of the view point of the camera |
[in] | up_x | the x component of the view up direction of the camera |
[in] | up_y | the y component of the view up direction of the camera |
[in] | up_z | the y component of the view up direction of the camera |
[in] | viewport | the viewport to modify camera of (0 modifies all cameras) |
Definition at line 1770 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setCameraPosition | ( | double | pos_x, |
double | pos_y, | ||
double | pos_z, | ||
double | up_x, | ||
double | up_y, | ||
double | up_z, | ||
int | viewport = 0 |
||
) |
Set the camera location and viewup according to the given arguments.
[in] | pos_x | the x coordinate of the camera location |
[in] | pos_y | the y coordinate of the camera location |
[in] | pos_z | the z coordinate of the camera location |
[in] | up_x | the x component of the view up direction of the camera |
[in] | up_y | the y component of the view up direction of the camera |
[in] | up_z | the z component of the view up direction of the camera |
[in] | viewport | the viewport to modify camera of (0 modifies all cameras) |
Definition at line 1796 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setFullScreen | ( | bool | mode | ) |
Enables/Disabled the underlying window mode to full screen.
[in] | mode | true for full screen, false otherwise |
Definition at line 3912 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::setPointCloudRenderingProperties | ( | int | property, |
double | val1, | ||
double | val2, | ||
double | val3, | ||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Set the rendering properties of a PointCloud (3x values - e.g., RGB)
[in] | property | the property type |
[in] | val1 | the first value to be set |
[in] | val2 | the second value to be set |
[in] | val3 | the third value to be set |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud's rendering properties should be modified (default: all) |
Definition at line 1265 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::setPointCloudRenderingProperties | ( | int | property, |
double | value, | ||
const std::string & | id = "cloud" , |
||
int | viewport = 0 |
||
) |
Set the rendering properties of a PointCloud.
[in] | property | the property type |
[in] | value | the value to be set |
[in] | id | the point cloud object id (default: cloud) |
[in] | viewport | the view port where the Point Cloud's rendering properties should be modified (default: all) |
Definition at line 1340 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::setPointCloudSelected | ( | const bool | selected, |
const std::string & | id = "cloud" |
||
) |
Set whether the point cloud is selected or not.
[in] | selected | whether the cloud is selected or not (true = selected) |
[in] | id | the point cloud object id (default: cloud) |
Definition at line 1396 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setPosition | ( | int | x, |
int | y | ||
) |
Set the position in screen coordinates.
[in] | x | where to move the window to (X) |
[in] | y | where to move the window to (Y) |
Definition at line 3936 of file pcl_visualizer.cpp.
Changes the visual representation for all actors to points representation.
Definition at line 3094 of file pcl_visualizer.cpp.
Changes the visual representation for all actors to surface representation.
Definition at line 3075 of file pcl_visualizer.cpp.
Changes the visual representation for all actors to wireframe representation.
Definition at line 3113 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::setShapeRenderingProperties | ( | int | property, |
double | value, | ||
const std::string & | id, | ||
int | viewport = 0 |
||
) |
Set the rendering properties of a shape.
[in] | property | the property type |
[in] | value | the value to be set |
[in] | id | the shape object id |
[in] | viewport | the view port where the shape's properties should be modified (default: all) |
Definition at line 1471 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::setShapeRenderingProperties | ( | int | property, |
double | val1, | ||
double | val2, | ||
double | val3, | ||
const std::string & | id, | ||
int | viewport = 0 |
||
) |
Set the rendering properties of a shape (3x values - e.g., RGB)
[in] | property | the property type |
[in] | val1 | the first value to be set |
[in] | val2 | the second value to be set |
[in] | val3 | the third value to be set |
[in] | id | the shape object id |
[in] | viewport | the view port where the shape's properties should be modified (default: all) |
Definition at line 1426 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setShowFPS | ( | bool | show_fps | ) |
Sets whether the 2D overlay text showing the framerate of the window is displayed or not.
[in] | show_fps | determines whether the fps text will be shown or not. |
Definition at line 3133 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setSize | ( | int | xw, |
int | yw | ||
) |
Set the window size in screen coordinates.
[in] | xw | window size in horizontal (pixels) |
[in] | yw | window size in vertical (pixels) |
Definition at line 3944 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setupInteractor | ( | vtkRenderWindowInteractor * | iren, |
vtkRenderWindow * | win | ||
) |
Set up our unique PCL interactor style for a given vtkRenderWindowInteractor object attached to a given vtkRenderWindow.
[in,out] | iren | the vtkRenderWindowInteractor object to set up |
[in,out] | win | a vtkRenderWindow object that the interactor is attached to |
Definition at line 277 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setupInteractor | ( | vtkRenderWindowInteractor * | iren, |
vtkRenderWindow * | win, | ||
vtkInteractorStyle * | style | ||
) |
Set up PCLVisualizer with custom interactor style for a given vtkRenderWindowInteractor object attached to a given vtkRenderWindow.
[in,out] | iren | the vtkRenderWindowInteractor object to set up |
[in,out] | win | a vtkRenderWindow object that the interactor is attached to |
[in,out] | style | a vtkInteractorStyle object |
Definition at line 320 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setUseVbos | ( | bool | use_vbos | ) |
Use Vertex Buffer Objects renderers.
[in] | use_vbos | set to true to use VBOs |
Definition at line 4024 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setWindowBorders | ( | bool | mode | ) |
Enables or disable the underlying window borders.
[in] | mode | true for borders, false otherwise |
Definition at line 3928 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::setWindowName | ( | const std::string & | name | ) |
Set the visualizer window name.
[in] | name | the name of the window |
Definition at line 3920 of file pcl_visualizer.cpp.
Spin method. Calls the interactor and runs an internal loop.
Definition at line 425 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::spinOnce | ( | int | time = 1 , |
bool | force_redraw = false |
||
) |
Spin once method. Calls the interactor and updates the screen once.
[in] | time | - How long (in ms) should the visualization loop be allowed to run. |
[in] | force_redraw | - if false it might return without doing anything if the interactor's framerate does not require a redraw yet. |
Definition at line 435 of file pcl_visualizer.cpp.
Update camera parameters and render.
Definition at line 1627 of file pcl_visualizer.cpp.
void pcl::visualization::PCLVisualizer::updateCells | ( | vtkSmartPointer< vtkIdTypeArray > & | cells, |
vtkSmartPointer< vtkIdTypeArray > & | initcells, | ||
vtkIdType | nr_points | ||
) | [private] |
Updates a set of cells (vtkIdTypeArray) if the number of points in a cloud changes.
[out] | cells | the vtkIdTypeArray object (set of cells) to update |
[out] | initcells | a previously saved set of cells. If the number of points in the current cloud is higher than the number of cells in cells, and initcells contains enough data, then a copy from it will be made instead of regenerating the entire array. |
[in] | nr_points | the number of points in the new cloud. This dictates how many cells we need to generate |
Definition at line 3723 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::updateColorHandlerIndex | ( | const std::string & | id, |
int | index | ||
) |
Update/set the color index of a renderered PointCloud based on its ID.
[in] | id | the point cloud object id |
[in] | index | the color handler index to use |
Definition at line 2729 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::updateCorrespondences | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | source_points, |
const typename pcl::PointCloud< PointT >::ConstPtr & | target_points, | ||
const pcl::Correspondences & | correspondences, | ||
int | nth, | ||
const std::string & | id = "correspondences" |
||
) |
Update the specified correspondences to the display.
[in] | source_points | The source points |
[in] | target_points | The target points |
[in] | correspondences | The mapping from source points to target points. Each element must be an index into target_points |
[in] | nth | display only the Nth correspondence (e.g., skip the rest) |
[in] | id | the polygon object id (default: "correspondences") |
Definition at line 1095 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::updatePointCloud | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const std::string & | id = "cloud" |
||
) |
Updates the XYZ data for an existing cloud object id on screen.
[in] | cloud | the input point cloud dataset |
[in] | id | the point cloud object id to update (default: cloud) |
Definition at line 1385 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::updatePointCloud | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const PointCloudGeometryHandler< PointT > & | geometry_handler, | ||
const std::string & | id = "cloud" |
||
) |
Updates the XYZ data for an existing cloud object id on screen.
[in] | cloud | the input point cloud dataset |
[in] | geometry_handler | the geometry handler to use |
[in] | id | the point cloud object id to update (default: cloud) |
Definition at line 1416 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::updatePointCloud | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const PointCloudColorHandler< PointT > & | color_handler, | ||
const std::string & | id = "cloud" |
||
) |
Updates the XYZ data for an existing cloud object id on screen.
[in] | cloud | the input point cloud dataset |
[in] | color_handler | the color handler to use |
[in] | id | the point cloud object id to update (default: cloud) |
Definition at line 1450 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::updatePointCloud | ( | const pcl::PointCloud< pcl::PointXYZ >::ConstPtr & | cloud, |
const std::string & | id = "cloud" |
||
) | [inline] |
Updates the XYZ data for an existing cloud object id on screen.
[in] | cloud | the input point cloud dataset |
[in] | id | the point cloud object id to update (default: cloud) |
Definition at line 807 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::updatePointCloud | ( | const pcl::PointCloud< pcl::PointXYZRGB >::ConstPtr & | cloud, |
const std::string & | id = "cloud" |
||
) | [inline] |
Updates the XYZRGB data for an existing cloud object id on screen.
[in] | cloud | the input point cloud dataset |
[in] | id | the point cloud object id to update (default: cloud) |
Definition at line 819 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::updatePointCloud | ( | const pcl::PointCloud< pcl::PointXYZRGBA >::ConstPtr & | cloud, |
const std::string & | id = "cloud" |
||
) | [inline] |
Updates the XYZRGBA data for an existing cloud object id on screen.
[in] | cloud | the input point cloud dataset |
[in] | id | the point cloud object id to update (default: cloud) |
Definition at line 832 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::updatePointCloudPose | ( | const std::string & | id, |
const Eigen::Affine3f & | pose | ||
) |
Set the pose of an existing point cloud.
Returns false if the point cloud doesn't exist, true if the pose was succesfully updated.
[in] | id | the point cloud object id (i.e., given on addPointCloud etc.) |
[in] | pose | the new pose |
Definition at line 1662 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::updatePolygonMesh | ( | const typename pcl::PointCloud< PointT >::ConstPtr & | cloud, |
const std::vector< pcl::Vertices > & | vertices, | ||
const std::string & | id = "polygon" |
||
) |
Update a PolygonMesh object on screen.
[in] | cloud | the polygonal mesh point cloud |
[in] | vertices | the polygonal mesh vertices |
[in] | id | the polygon object id (default: "polygon") |
Definition at line 1698 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::updatePolygonMesh | ( | const pcl::PolygonMesh & | polymesh, |
const std::string & | id = "polygon" |
||
) |
Update a PolygonMesh object on screen.
[in] | polymesh | the polygonal mesh |
[in] | id | the polygon object id (default: "polygon") |
Definition at line 2906 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::updateShapePose | ( | const std::string & | id, |
const Eigen::Affine3f & | pose | ||
) |
Set the pose of an existing shape.
Returns false if the shape doesn't exist, true if the pose was succesfully updated.
[in] | id | the shape or cloud object id (i.e., given on addLine etc.) |
[in] | pose | the new pose |
Definition at line 1639 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::updateSphere | ( | const PointT & | center, |
double | radius, | ||
double | r, | ||
double | g, | ||
double | b, | ||
const std::string & | id = "sphere" |
||
) |
Update an existing sphere shape from a point and a radius.
[in] | center | the center of the sphere |
[in] | radius | the radius of the sphere |
[in] | r | the red channel of the color that the sphere should be rendered with |
[in] | g | the green channel of the color that the sphere should be rendered with |
[in] | b | the blue channel of the color that the sphere should be rendered with |
[in] | id | the sphere id/name (default: "sphere") |
Definition at line 606 of file pcl_visualizer.hpp.
bool pcl::visualization::PCLVisualizer::updateText | ( | const std::string & | text, |
int | xpos, | ||
int | ypos, | ||
const std::string & | id = "" |
||
) |
Update a text to screen.
[in] | text | the text to update |
[in] | xpos | the new X position on screen |
[in] | ypos | the new Y position on screen |
[in] | id | the text object id (default: equal to the "text" parameter) |
Definition at line 2647 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::updateText | ( | const std::string & | text, |
int | xpos, | ||
int | ypos, | ||
double | r, | ||
double | g, | ||
double | b, | ||
const std::string & | id = "" |
||
) |
Update a text to screen.
[in] | text | the text to update |
[in] | xpos | the new X position on screen |
[in] | ypos | the new Y position on screen |
[in] | r | the red color value |
[in] | g | the green color value |
[in] | b | the blue color vlaue |
[in] | id | the text object id (default: equal to the "text" parameter) |
Definition at line 2672 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::updateText | ( | const std::string & | text, |
int | xpos, | ||
int | ypos, | ||
int | fontsize, | ||
double | r, | ||
double | g, | ||
double | b, | ||
const std::string & | id = "" |
||
) |
Update a text to screen.
[in] | text | the text to update |
[in] | xpos | the new X position on screen |
[in] | ypos | the new Y position on screen |
[in] | fontsize | the fontsize of the text |
[in] | r | the red color value |
[in] | g | the green color value |
[in] | b | the blue color vlaue |
[in] | id | the text object id (default: equal to the "text" parameter) |
Definition at line 2699 of file pcl_visualizer.cpp.
bool pcl::visualization::PCLVisualizer::wasStopped | ( | ) | const |
Returns true when the user tried to close the window.
Definition at line 3998 of file pcl_visualizer.cpp.
vtkSmartPointer<vtkOrientationMarkerWidget> pcl::visualization::PCLVisualizer::axes_widget_ [private] |
Internal pointer to widget which contains a set of axes.
Definition at line 1763 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::camera_set_ [private] |
Boolean that holds whether or not the camera parameters were manually initialized.
Definition at line 1766 of file pcl_visualizer.h.
Internal list with actor pointers and name IDs for point clouds.
Definition at line 1754 of file pcl_visualizer.h.
Internal list with actor pointers and viewpoint for coordinates.
Definition at line 1760 of file pcl_visualizer.h.
vtkSmartPointer<ExitCallback> pcl::visualization::PCLVisualizer::exit_callback_ [private] |
Definition at line 1742 of file pcl_visualizer.h.
vtkSmartPointer<ExitMainLoopTimerCallback> pcl::visualization::PCLVisualizer::exit_main_loop_timer_callback_ [private] |
Callback object enabling us to leave the main loop, when a timer fires.
Definition at line 1741 of file pcl_visualizer.h.
vtkSmartPointer<vtkRenderWindowInteractor> pcl::visualization::PCLVisualizer::interactor_ [protected] |
The render window interactor.
Definition at line 1685 of file pcl_visualizer.h.
vtkSmartPointer<vtkRendererCollection> pcl::visualization::PCLVisualizer::rens_ [private] |
The collection of renderers used.
Definition at line 1745 of file pcl_visualizer.h.
Internal list with actor pointers and name IDs for shapes.
Definition at line 1757 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::stopped_ [private] |
Set to false if the interaction loop is running.
Definition at line 1735 of file pcl_visualizer.h.
vtkSmartPointer<PCLVisualizerInteractorStyle> pcl::visualization::PCLVisualizer::style_ [private] |
The render window interactor style.
Definition at line 1751 of file pcl_visualizer.h.
int pcl::visualization::PCLVisualizer::timer_id_ [private] |
Global timer ID. Used in destructor only.
Definition at line 1738 of file pcl_visualizer.h.
vtkSmartPointer<FPSCallback> pcl::visualization::PCLVisualizer::update_fps_ [private] |
The FPSCallback object for the current visualizer.
Definition at line 1731 of file pcl_visualizer.h.
bool pcl::visualization::PCLVisualizer::use_vbos_ [private] |
Boolean that holds whether or not to use the vtkVertexBufferObjectMapper.
Definition at line 1769 of file pcl_visualizer.h.
vtkSmartPointer<vtkRenderWindow> pcl::visualization::PCLVisualizer::win_ [private] |
The render window.
Definition at line 1748 of file pcl_visualizer.h.