Point Cloud Library (PCL)
1.10.0
|
39 #ifndef PCL_IMPL_POINT_TYPES_HPP_
40 #define PCL_IMPL_POINT_TYPES_HPP_
43 # pragma GCC system_header
54 #define PCL_POINT_TYPES \
64 (pcl::InterestPoint) \
68 (pcl::PointXYZRGBNormal) \
69 (pcl::PointXYZINormal) \
70 (pcl::PointXYZLNormal) \
71 (pcl::PointWithRange) \
72 (pcl::PointWithViewpoint) \
73 (pcl::MomentInvariants) \
74 (pcl::PrincipalRadiiRSD) \
76 (pcl::PrincipalCurvatures) \
77 (pcl::PFHSignature125) \
78 (pcl::PFHRGBSignature250) \
80 (pcl::CPPFSignature) \
81 (pcl::PPFRGBSignature) \
82 (pcl::NormalBasedSignature12) \
83 (pcl::FPFHSignature33) \
84 (pcl::VFHSignature308) \
85 (pcl::GASDSignature512) \
86 (pcl::GASDSignature984) \
87 (pcl::GASDSignature7992) \
88 (pcl::GRSDSignature21) \
89 (pcl::ESFSignature640) \
90 (pcl::BRISKSignature512) \
92 (pcl::IntensityGradient) \
93 (pcl::PointWithScale) \
95 (pcl::ShapeContext1980) \
96 (pcl::UniqueShapeContext1960) \
100 (pcl::ReferenceFrame) \
104 #define PCL_RGB_POINT_TYPES \
105 (pcl::PointXYZRGBA) \
107 (pcl::PointXYZRGBL) \
108 (pcl::PointXYZRGBNormal) \
112 #define PCL_XYZ_POINT_TYPES \
116 (pcl::PointXYZRGBA) \
118 (pcl::PointXYZRGBL) \
120 (pcl::InterestPoint) \
122 (pcl::PointXYZRGBNormal) \
123 (pcl::PointXYZINormal) \
124 (pcl::PointXYZLNormal) \
125 (pcl::PointWithRange) \
126 (pcl::PointWithViewpoint) \
127 (pcl::PointWithScale) \
132 #define PCL_XYZL_POINT_TYPES \
134 (pcl::PointXYZRGBL) \
135 (pcl::PointXYZLNormal)
138 #define PCL_NORMAL_POINT_TYPES \
141 (pcl::PointXYZRGBNormal) \
142 (pcl::PointXYZINormal) \
143 (pcl::PointXYZLNormal) \
147 #define PCL_FEATURE_POINT_TYPES \
148 (pcl::PFHSignature125) \
149 (pcl::PFHRGBSignature250) \
150 (pcl::PPFSignature) \
151 (pcl::CPPFSignature) \
152 (pcl::PPFRGBSignature) \
153 (pcl::NormalBasedSignature12) \
154 (pcl::FPFHSignature33) \
155 (pcl::VFHSignature308) \
156 (pcl::GASDSignature512) \
157 (pcl::GASDSignature984) \
158 (pcl::GASDSignature7992) \
159 (pcl::GRSDSignature21) \
160 (pcl::ESFSignature640) \
161 (pcl::BRISKSignature512) \
169 using Array4fMap = Eigen::Map<Eigen::Array4f, Eigen::Aligned>;
176 using Vector3c = Eigen::Matrix<std::uint8_t, 3, 1>;
179 using Vector4c = Eigen::Matrix<std::uint8_t, 4, 1>;
183 #define PCL_ADD_UNION_POINT4D \
184 union EIGEN_ALIGN16 { \
193 #define PCL_ADD_EIGEN_MAPS_POINT4D \
194 inline pcl::Vector3fMap getVector3fMap () { return (pcl::Vector3fMap (data)); } \
195 inline pcl::Vector3fMapConst getVector3fMap () const { return (pcl::Vector3fMapConst (data)); } \
196 inline pcl::Vector4fMap getVector4fMap () { return (pcl::Vector4fMap (data)); } \
197 inline pcl::Vector4fMapConst getVector4fMap () const { return (pcl::Vector4fMapConst (data)); } \
198 inline pcl::Array3fMap getArray3fMap () { return (pcl::Array3fMap (data)); } \
199 inline pcl::Array3fMapConst getArray3fMap () const { return (pcl::Array3fMapConst (data)); } \
200 inline pcl::Array4fMap getArray4fMap () { return (pcl::Array4fMap (data)); } \
201 inline pcl::Array4fMapConst getArray4fMap () const { return (pcl::Array4fMapConst (data)); }
203 #define PCL_ADD_POINT4D \
204 PCL_ADD_UNION_POINT4D \
205 PCL_ADD_EIGEN_MAPS_POINT4D
207 #define PCL_ADD_UNION_NORMAL4D \
208 union EIGEN_ALIGN16 { \
218 #define PCL_ADD_EIGEN_MAPS_NORMAL4D \
219 inline pcl::Vector3fMap getNormalVector3fMap () { return (pcl::Vector3fMap (data_n)); } \
220 inline pcl::Vector3fMapConst getNormalVector3fMap () const { return (pcl::Vector3fMapConst (data_n)); } \
221 inline pcl::Vector4fMap getNormalVector4fMap () { return (pcl::Vector4fMap (data_n)); } \
222 inline pcl::Vector4fMapConst getNormalVector4fMap () const { return (pcl::Vector4fMapConst (data_n)); }
224 #define PCL_ADD_NORMAL4D \
225 PCL_ADD_UNION_NORMAL4D \
226 PCL_ADD_EIGEN_MAPS_NORMAL4D
228 #define PCL_ADD_UNION_RGB \
242 std::uint32_t rgba; \
245 #define PCL_ADD_EIGEN_MAPS_RGB \
246 inline Eigen::Vector3i getRGBVector3i () { return (Eigen::Vector3i (r, g, b)); } \
247 inline const Eigen::Vector3i getRGBVector3i () const { return (Eigen::Vector3i (r, g, b)); } \
248 inline Eigen::Vector4i getRGBVector4i () { return (Eigen::Vector4i (r, g, b, a)); } \
249 inline const Eigen::Vector4i getRGBVector4i () const { return (Eigen::Vector4i (r, g, b, a)); } \
250 inline Eigen::Vector4i getRGBAVector4i () { return (Eigen::Vector4i (r, g, b, a)); } \
251 inline const Eigen::Vector4i getRGBAVector4i () const { return (Eigen::Vector4i (r, g, b, a)); } \
252 inline pcl::Vector3cMap getBGRVector3cMap () { return (pcl::Vector3cMap (reinterpret_cast<std::uint8_t*> (&rgba))); } \
253 inline pcl::Vector3cMapConst getBGRVector3cMap () const { return (pcl::Vector3cMapConst (reinterpret_cast<const std::uint8_t*> (&rgba))); } \
254 inline pcl::Vector4cMap getBGRAVector4cMap () { return (pcl::Vector4cMap (reinterpret_cast<std::uint8_t*> (&rgba))); } \
255 inline pcl::Vector4cMapConst getBGRAVector4cMap () const { return (pcl::Vector4cMapConst (reinterpret_cast<const std::uint8_t*> (&rgba))); }
257 #define PCL_ADD_RGB \
259 PCL_ADD_EIGEN_MAPS_RGB
261 #define PCL_ADD_INTENSITY \
267 #define PCL_ADD_INTENSITY_8U \
270 std::uint8_t intensity; \
273 #define PCL_ADD_INTENSITY_32U \
276 std::uint32_t intensity; \
295 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
306 x = _x; y = _y; z = _z;
364 friend std::ostream&
operator << (std::ostream& os,
const RGB& p);
381 intensity = p.intensity;
407 intensity = p.intensity;
415 #if defined(_LIBCPP_VERSION) && _LIBCPP_VERSION <= 1101
416 operator unsigned char()
const
439 intensity = p.intensity;
472 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
504 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
560 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
627 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
658 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
708 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
709 h = p.
h; s = p.
s; v = p.
v;
716 h = s = v = data_c[3] = 0;
722 h = _h; v = _v; s = _s;
799 normal_x = p.normal_x; normal_y = p.normal_y; normal_z = p.normal_z;
806 normal_x = normal_y = normal_z = data_n[3] = 0.0f;
810 inline Normal (
float n_x,
float n_y,
float n_z)
812 normal_x = n_x; normal_y = n_y; normal_z = n_z;
836 normal_x = p.normal_x; normal_y = p.normal_y; normal_z = p.normal_z;
842 normal_x = normal_y = normal_z = data_n[3] = 0.0f;
845 inline Axis (
float n_x,
float n_y,
float n_z)
847 normal_x = n_x; normal_y = n_y; normal_z = n_z;
879 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
880 normal_x = p.normal_x; normal_y = p.normal_y; normal_z = p.normal_z; data_n[3] = 0.0f;
888 normal_x = normal_y = normal_z = data_n[3] = 0.0f;
947 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
948 normal_x = p.normal_x; normal_y = p.normal_y; normal_z = p.normal_z; data_n[3] = 0.0f;
959 normal_x = normal_y = normal_z = data_n[3] = 0.0f;
990 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
991 normal_x = p.normal_x; normal_y = p.normal_y; normal_z = p.normal_z; data_n[3] = 0.0f;
1000 normal_x = normal_y = normal_z = data_n[3] = 0.0f;
1033 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
1034 normal_x = p.normal_x; normal_y = p.normal_y; normal_z = p.normal_z; data_n[3] = 0.0f;
1043 normal_x = normal_y = normal_z = data_n[3] = 0.0f;
1076 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
1115 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
1120 float _vp_x = 0.0f,
float _vp_y = 0.0f,
float _vp_z = 0.0f)
1122 x = _x; y = _y; z = _z;
1124 vp_x = _vp_x; vp_y = _vp_y; vp_z = _vp_z;
1160 #if defined(_LIBCPP_VERSION) && _LIBCPP_VERSION <= 1101
1161 operator unsigned char()
const
1336 inline const Eigen::Map<const Eigen::Vector3f>
getXAxisVector3fMap ()
const {
return (Eigen::Vector3f::Map (x_axis)); }
1338 inline const Eigen::Map<const Eigen::Vector3f>
getYAxisVector3fMap ()
const {
return (Eigen::Vector3f::Map (y_axis)); }
1340 inline const Eigen::Map<const Eigen::Vector3f>
getZAxisVector3fMap ()
const {
return (Eigen::Vector3f::Map (z_axis)); }
1341 inline Eigen::Map<Eigen::Matrix3f>
getMatrix3fMap () {
return (Eigen::Matrix3f::Map (rf)); }
1342 inline const Eigen::Map<const Eigen::Matrix3f>
getMatrix3fMap ()
const {
return (Eigen::Matrix3f::Map (rf)); }
1352 std::copy_n(p.
rf, 9, rf);
1357 std::fill_n(x_axis, 3, 0);
1358 std::fill_n(y_axis, 3, 0);
1359 std::fill_n(z_axis, 3, 0);
1521 friend std::ostream&
operator << (std::ostream& os,
const IntensityGradient& p);
1563 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
1592 inline PointWithScale (
float _x,
float _y,
float _z,
float _scale,
float _angle,
float _response,
int _octave)
1635 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
1646 normal_x = normal_y = normal_z = data_n[3] = 0.0f;
1672 x = p.x; y = p.y; z = p.z; data[3] = 1.0f;
1680 x = y = z = 0.0f; data[3] = 1.0f;
1688 template <
int N> std::ostream&
1696 [&os](
const auto& hist) { os <<
", " << hist; });
A 2D point structure representing pixel image coordinates.
static int descriptorSize()
PointXYZRGBA(const _PointXYZRGBA &p)
Defines all the PCL and non-PCL macros used.
A point structure representing the Point Feature Histogram (PFH).
This file defines compatibility wrappers for low level I/O functions.
A point structure representing Digital Elevation Map.
A point structure representing normal coordinates and the surface curvature estimate.
friend std::ostream & operator<<(std::ostream &os, const VFHSignature308 &p)
A point structure representing the minimum and maximum surface radii (in meters) computed using RSD.
Axis(float n_x, float n_y, float n_z)
const Eigen::Map< const Eigen::Vector3f > getYAxisVector3fMap() const
PointXYZI(const _PointXYZI &p)
A point structure for storing the Point Pair Color Feature (PPFRGB) values.
float scale
Diameter of the meaningful keypoint neighborhood.
friend std::ostream & operator<<(std::ostream &os, const ESFSignature640 &p)
Eigen::Matrix< std::uint8_t, 3, 1 > Vector3c
friend std::ostream & operator<<(std::ostream &os, const ShapeContext1980 &p)
friend std::ostream & operator<<(std::ostream &os, const CPPFSignature &p)
A surfel, that is, a point structure representing Euclidean xyz coordinates, together with normal coo...
A point structure representing the Normal Based Signature for a feature matrix of 4-by-3.
static int descriptorSize()
A point structure representing the Globally Aligned Spatial Distribution (GASD) shape descriptor.
PointDEM(const _PointDEM &p)
static int descriptorSize()
friend std::ostream & operator<<(std::ostream &os, const PointXYZL &p)
Eigen::Map< Eigen::Vector3f > getYAxisVector3fMap()
friend std::ostream & operator<<(std::ostream &os, const GASDSignature512 &p)
Normal(float n_x, float n_y, float n_z)
static int descriptorSize()
static int descriptorSize()
A point structure representing a description of whether a point is lying on a surface boundary or not...
static int descriptorSize()
static int descriptorSize()
float angle
Computed orientation of the keypoint (-1 if not applicable).
friend std::ostream & operator<<(std::ostream &os, const RGB &p)
A point structure representing the Fast Point Feature Histogram (FPFH).
friend std::ostream & operator<<(std::ostream &os, const UniqueShapeContext1960 &p)
unsigned char descriptor[64]
friend std::ostream & operator<<(std::ostream &os, const Boundary &p)
friend std::ostream & operator<<(std::ostream &os, const SHOT1344 &p)
friend std::ostream & operator<<(std::ostream &os, const PFHSignature125 &p)
friend std::ostream & operator<<(std::ostream &os, const GRSDSignature21 &p)
friend std::ostream & operator<<(std::ostream &os, const SHOT352 &p)
A point structure representing Euclidean xyz coordinates, intensity, together with normal coordinates...
float principal_curvature_z
float principal_curvature[3]
A point structure representing the grayscale intensity in single-channel images.
const Eigen::Map< const Eigen::Vector3f > getZAxisVector3fMap() const
friend std::ostream & operator<<(std::ostream &os, const PointWithScale &p)
PointWithScale(float _x, float _y, float _z, float _scale)
static int descriptorSize()
A point structure representing Euclidean xyz coordinates, and the RGB color.
Eigen::Map< Vector3c > Vector3cMap
A point structure representing a Unique Shape Context.
PointXYZRGBL(std::uint8_t _r, std::uint8_t _g, std::uint8_t _b, std::uint32_t _label)
PointNormal(const _PointNormal &p)
A point structure representing Euclidean xyz coordinates together with the viewpoint from which it wa...
A point structure representing Euclidean xyz coordinates, and the intensity value.
PointWithScale(float _x, float _y, float _z, float _scale, float _angle, float _response, int _octave)
friend std::ostream & operator<<(std::ostream &os, const FPFHSignature33 &p)
friend std::ostream & operator<<(std::ostream &os, const BorderDescription &p)
const Eigen::Map< const Eigen::Vector3f > getXAxisVector3fMap() const
A point structure representing the grayscale intensity in single-channel images.
int octave
octave (pyramid layer) from which the keypoint has been extracted.
Intensity(const _Intensity &p)
A point structure representing a Shape Context.
friend std::ostream & operator<<(std::ostream &os, const Intensity32u &p)
A point structure representing the GFPFH descriptor with 16 bins.
friend std::ostream & operator<<(std::ostream &os, const NormalBasedSignature12 &p)
std::ostream & operator<<(std::ostream &os, const BivariatePolynomialT< real > &p)
friend std::ostream & operator<<(std::ostream &os, const PointSurfel &p)
PointXYZRGB(std::uint8_t _r, std::uint8_t _g, std::uint8_t _b)
friend std::ostream & operator<<(std::ostream &os, const Intensity8u &p)
Eigen::Map< Eigen::Array3f > Array3fMap
A point structure representing the Globally Aligned Spatial Distribution (GASD) shape and color descr...
friend std::ostream & operator<<(std::ostream &os, const BRISKSignature512 &p)
friend std::ostream & operator<<(std::ostream &os, const GASDSignature7992 &p)
A point structure representing Euclidean xyz coordinates, and the RGBA color.
PointXYZHSV(const _PointXYZHSV &p)
PointXYZL(const _PointXYZL &p)
friend std::ostream & operator<<(std::ostream &os, const PrincipalCurvatures &p)
PointXYZRGBL(const _PointXYZRGBL &p)
static int descriptorSize()
static int descriptorSize()
A point structure representing the Global Radius-based Surface Descriptor (GRSD).
A point structure representing Euclidean xyz coordinates.
A point structure for storing the Point Pair Feature (CPPF) values.
A point structure representing the grayscale intensity in single-channel images.
PointXYZINormal(const _PointXYZINormal &p)
A point structure for storing the Point Pair Feature (PPF) values.
const Eigen::Map< const Vector4c, Eigen::Aligned > Vector4cMapConst
PointXYZLNormal(const _PointXYZLNormal &p)
Eigen::Map< Eigen::Vector3f > getZAxisVector3fMap()
friend std::ostream & operator<<(std::ostream &os, const GASDSignature984 &p)
float principal_curvature_y
PointXYZI(float _intensity)
Eigen::Map< Eigen::Array4f, Eigen::Aligned > Array4fMap
A point structure representing the Binary Robust Invariant Scalable Keypoints (BRISK).
const Eigen::Map< const Eigen::Array4f, Eigen::Aligned > Array4fMapConst
A point structure representing an Axis using its normal coordinates.
friend std::ostream & operator<<(std::ostream &os, const PointXYZLNormal &p)
PointWithScale(const _PointWithScale &p)
#define PCL_MAKE_ALIGNED_OPERATOR_NEW
Macro to signal a class requires a custom allocator.
A structure representing RGB color information.
PointXYZ(float _x, float _y, float _z)
Intensity8u(const _Intensity8u &p)
A point structure representing the Point Feature Histogram with colors (PFHRGB).
A point structure representing the three moment invariants.
A point structure representing an interest point with Euclidean xyz coordinates, and an interest valu...
friend std::ostream & operator<<(std::ostream &os, const PointDEM &p)
PointXYZRGB(const _PointXYZRGB &p)
friend std::ostream & operator<<(std::ostream &os, const PFHRGBSignature250 &p)
A point structure representing Euclidean xyz coordinates, together with normal coordinates and the su...
float principal_curvature_x
A 2D point structure representing Euclidean xy coordinates.
friend std::ostream & operator<<(std::ostream &os, const PrincipalRadiiRSD &p)
static int descriptorSize()
friend std::ostream & operator<<(std::ostream &os, const PointXYZINormal &p)
friend std::ostream & operator<<(std::ostream &os, const Label &p)
friend std::ostream & operator<<(std::ostream &os, const Narf36 &p)
std::bitset< 32 > BorderTraits
Data type to store extended information about a transition from foreground to backgroundSpecification...
A point structure representing the principal curvatures and their magnitudes.
PointXYZ(const _PointXYZ &p)
A point structure representing the Narf descriptor.
friend std::ostream & operator<<(std::ostream &os, const PointXY &p)
static int descriptorSize()
float response
The response by which the most strong keypoints have been selected.
const Eigen::Map< const Eigen::Vector3f > Vector3fMapConst
static int descriptorSize()
A point structure representing the Ensemble of Shape Functions (ESF).
friend std::ostream & operator<<(std::ostream &os, const GFPFHSignature16 &p)
A point structure representing a 3-D position and scale.
static int descriptorSize()
A point structure representing the Globally Aligned Spatial Distribution (GASD) shape and color descr...
A point structure representing Euclidean xyz coordinates, padded with an extra range float.
A point structure representing an N-D histogram.
friend std::ostream & operator<<(std::ostream &os, const PointNormal &p)
ReferenceFrame(const _ReferenceFrame &p)
Eigen::Map< Eigen::Vector3f > getXAxisVector3fMap()
std::uint8_t boundary_point
friend std::ostream & operator<<(std::ostream &os, const PointWithRange &p)
friend std::ostream & operator<<(std::ostream &os, const Normal &p)
A point structure representing Euclidean xyz coordinates, and the RGB color, together with normal coo...
Eigen::Matrix< std::uint8_t, 4, 1 > Vector4c
const Eigen::Map< const Vector3c > Vector3cMapConst
friend std::ostream & operator<<(std::ostream &os, const PointXYZI &p)
static int descriptorSize()
static int descriptorSize()
A point structure representing Euclidean xyz coordinates, a label, together with normal coordinates a...
A structure to store if a point in a range image lies on a border between an obstacle and the backgro...
A point structure representing the generic Signature of Histograms of OrienTations (SHOT) - shape+col...
friend std::ostream & operator<<(std::ostream &os, const MomentInvariants &p)
A point structure representing the generic Signature of Histograms of OrienTations (SHOT) - shape onl...
friend std::ostream & operator<<(std::ostream &os, const PPFRGBSignature &p)
Eigen::Map< Eigen::Vector3f > Vector3fMap
const Eigen::Map< const Eigen::Matrix3f > getMatrix3fMap() const
friend std::ostream & operator<<(std::ostream &os, const PPFSignature &p)
friend std::ostream & operator<<(std::ostream &os, const PointXYZRGBNormal &p)
RGB(std::uint8_t _r, std::uint8_t _g, std::uint8_t _b)
Eigen::Map< Eigen::Vector4f, Eigen::Aligned > Vector4fMap
friend std::ostream & operator<<(std::ostream &os, const IntensityGradient &p)
PointWithRange(const _PointWithRange &p)
Eigen::Map< Vector4c, Eigen::Aligned > Vector4cMap
PointWithViewpoint(const _PointWithViewpoint &p)
PointXYZRGBNormal(const _PointXYZRGBNormal &p)
Eigen::Map< Eigen::Matrix3f > getMatrix3fMap()
static int descriptorSize()
const Eigen::Map< const Eigen::Array3f > Array3fMapConst
friend std::ostream & operator<<(std::ostream &os, const Intensity &p)
friend std::ostream & operator<<(std::ostream &os, const PointUV &p)
Intensity32u(const _Intensity32u &p)
A structure representing the Local Reference Frame of a point.
const Eigen::Map< const Eigen::Vector4f, Eigen::Aligned > Vector4fMapConst
A point structure representing the Viewpoint Feature Histogram (VFH).
PointWithViewpoint(float _x=0.0f, float _y=0.0f, float _z=0.0f, float _vp_x=0.0f, float _vp_y=0.0f, float _vp_z=0.0f)
PointXYZHSV(float _h, float _v, float _s)
A point structure representing the intensity gradient of an XYZI point cloud.
PointSurfel(const _PointSurfel &p)