37 #ifndef PCL_PCL_VISUALIZER_COMMON_H_
38 #define PCL_PCL_VISUALIZER_COMMON_H_
41 #pragma GCC system_header
44 #include <pcl/pcl_macros.h>
45 #include <pcl/visualization/eigen.h>
46 #include <vtkMatrix4x4.h>
47 #include <vtkSmartPointer.h>
48 #include <vtkLookupTable.h>
54 namespace visualization
64 getRandomColors (
double &r,
double &g,
double &b,
double min = 0.2,
double max = 2.8);
74 PCL_EXPORTS Eigen::Matrix4d
77 PCL_EXPORTS Eigen::Vector2i
78 worldToView (
const Eigen::Vector4d &world_pt,
const Eigen::Matrix4d &view_projection_matrix,
int width,
int height);
81 getViewFrustum (
const Eigen::Matrix4d &view_projection_matrix,
double planes[24]);
91 cullFrustum (
double planes[24],
const Eigen::Vector3d &min_bb,
const Eigen::Vector3d &max_bb);
94 viewScreenArea (
const Eigen::Vector3d &eye,
const Eigen::Vector3d &min_bb,
const Eigen::Vector3d &max_bb,
const Eigen::Matrix4d &view_projection_matrix,
int width,
int height);
173 double window_size[2];
174 double window_pos[2];
181 computeViewMatrix (Eigen::Matrix4d& view_mat)
const;
187 computeProjectionMatrix (Eigen::Matrix4d& proj)
const;
196 template<
typename Po
intT>
void
197 cvtWindowCoordinates (
const PointT& pt, Eigen::Vector4d& window_cord)
const;
209 template<
typename Po
intT>
void
210 cvtWindowCoordinates (
const PointT& pt, Eigen::Vector4d& window_cord,
const Eigen::Matrix4d& composite_mat)
const;
215 #include <pcl/visualization/common/impl/common.hpp>
Grey colormap (black to white)
PCL_EXPORTS void getViewFrustum(const Eigen::Matrix4d &view_projection_matrix, double planes[24])
This file defines compatibility wrappers for low level I/O functions.
Camera class holds a set of camera parameters together with the window pos/size.
LookUpTableRepresentationProperties
Float going from 0.0 (transparent) to 1.0 (opaque)
RenderingProperties
Set of rendering properties.
two doubles (min and max) or pcl::visualization::LookUpTableRepresentationProperties::PCL_VISUALIZER_...
PCL_EXPORTS void getRandomColors(double &r, double &g, double &b, double min=0.2, double max=2.8)
Get (good) random values for R/G/B.
A structure representing RGB color information.
3 floats (R, G, B) going from 0.0 (dark) to 1.0 (light)
PCL_EXPORTS Eigen::Matrix4d vtkToEigen(vtkMatrix4x4 *vtk_matrix)
Blue to red colormap (blue to white to red)
PCL_EXPORTS float viewScreenArea(const Eigen::Vector3d &eye, const Eigen::Vector3d &min_bb, const Eigen::Vector3d &max_bb, const Eigen::Matrix4d &view_projection_matrix, int width, int height)
colormap type pcl::visualization::LookUpTableRepresentationProperties
Set LUT range to min and max values of the data.
PCL_EXPORTS bool getColormapLUT(LookUpTableRepresentationProperties colormap_type, vtkSmartPointer< vtkLookupTable > &table)
Generate a lookup table for a colormap.
RenderingRepresentationProperties
double fovy
Field of view angle in y direction (radians).
A point structure representing Euclidean xyz coordinates, and the RGB color.
ShadingRepresentationProperties
PCL_EXPORTS Eigen::Vector2i worldToView(const Eigen::Vector4d &world_pt, const Eigen::Matrix4d &view_projection_matrix, int width, int height)
PCL_EXPORTS int cullFrustum(double planes[24], const Eigen::Vector3d &min_bb, const Eigen::Vector3d &max_bb)