Skip to content

Commit 2af2a1c

Browse files
authored
Merge pull request #38 from AutoModality/AM-363/pcl_point_type
added PointXYZIR
2 parents 72263dc + 7991286 commit 2af2a1c

File tree

3 files changed

+31
-0
lines changed

3 files changed

+31
-0
lines changed

CMakeLists.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ find_package(catkin REQUIRED COMPONENTS
1010
genmsg
1111
geometry_msgs
1212
nav_msgs
13+
pcl_conversions
1314
rosconsole
1415
roscpp
1516
rosbag
@@ -36,6 +37,7 @@ catkin_package(
3637
genmsg
3738
geometry_msgs
3839
nav_msgs
40+
pcl_conversions
3941
rosconsole
4042
roscpp
4143
rosbag

include/am_utils/point_types.h

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
#ifndef AM_UTILS_INCLUDE_AM_UTILS_POINT_TYPE_H_
2+
#define AM_UTILS_INCLUDE_AM_UTILS_POINT_TYPE_H_
3+
4+
#include <pcl-1.8/pcl/point_types.h>
5+
#include <pcl-1.8/pcl/point_types.h>
6+
#include <pcl-1.8/pcl/point_types.h>
7+
8+
namespace pcl {
9+
10+
struct PointXYZIR
11+
{
12+
PCL_ADD_POINT4D; // preferred way of adding a XYZ+padding
13+
float intensity;
14+
float range;
15+
EIGEN_MAKE_ALIGNED_OPERATOR_NEW // make sure our new allocators are aligned
16+
} EIGEN_ALIGN16; // enforce SSE padding for correct memory alignment
17+
18+
}
19+
20+
POINT_CLOUD_REGISTER_POINT_STRUCT (pcl::PointXYZIR,
21+
(float, x, x)
22+
(float, y, y)
23+
(float, z, z)
24+
(float, intensity, intensity)
25+
(float, range, range)
26+
)
27+
28+
#endif

package.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
<depend>genmsg</depend>
1515
<depend>geometry_msgs</depend>
1616
<depend>nav_msgs</depend>
17+
<depend>pcl_conversions</depend>
1718
<depend>rosconsole</depend>
1819
<depend>roscpp</depend>
1920
<depend>rosbag</depend>

0 commit comments

Comments
 (0)