├── manifest.xml
├── cmake
├── FindLIBLAS.cmake
├── FindE57RefImpl.cmake
├── FindPCL_IO_EXTRA.cmake
└── FindXerces.cmake
├── README
├── include
└── pcl
│ ├── double_utils.h
│ ├── extra_point_type.h
│ └── io
│ ├── cloud_collection.h
│ ├── impl
│ └── cloud_collection.hpp
│ ├── pts_io.h
│ ├── xyz_io.h
│ ├── vtx_io.h
│ ├── xya_io.h
│ ├── las_io.h
│ ├── ptx_io.h
│ ├── e57_io.h
│ ├── cloud_io.h
│ ├── filereaderd.h
│ └── points_to_rosmsg.h
├── tools
├── cvt2xyz.cpp
├── cvt2ptx.cpp
└── cvt2pcd.cpp
├── CMakeLists.txt
└── src
├── cloud_io.cpp
├── las_io.cpp
├── double_utils.cpp
├── xyz_io.cpp
├── xya_io.cpp
├── pts_io.cpp
├── cloud_collection.cpp
├── vtx_io.cpp
├── e57_io.cpp
└── ptx_io.cpp
/manifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | pcl_io_extra
5 |
6 |
7 | Adam Stambler
8 | BSD
9 |
10 | http://github.com/adasta/pcl_io_extra
11 |
12 |
13 |
14 |
15 |
16 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
--------------------------------------------------------------------------------
/cmake/FindLIBLAS.cmake:
--------------------------------------------------------------------------------
1 |
2 | include(FindPackageHandleStandardArgs)
3 |
4 | find_program(LIBLAS_CONFIG_PROG
5 | liblas-config
6 | /usr/local/bin
7 | )
8 |
9 | if (LIBLAS_CONFIG_PROG)
10 |
11 | exec_program(${LIBLAS_CONFIG_PROG} ARGS --libs OUTPUT_VARIABLE
12 | LIBLAS_LIBRARIES)
13 |
14 | set(LIBLAS_LIBRARIES ${LIBLAS_LIBRARIES} las)
15 | exec_program(${LIBLAS_CONFIG_PROG} ARGS --includes OUTPUT_VARIABLE
16 | LIBLAS_INCLUDE_DIRS)
17 |
18 | exec_program(${LIBLAS_CONFIG_PROG} ARGS --defines OUTPUT_VARIABLE
19 | LIBLAS_DEFINES)
20 |
21 | exec_program(${LIBLAS_CONFIG_PROG} ARGS --cxxflags OUTPUT_VARIABLE
22 | LIBLAS_CXXFLAGS)
23 |
24 | else()
25 | MESSAGE(FATAL_ERROR, "FindLIBAS.cmaek. liblas-config not found. liblas-config=${LIBLAS_CONFIG_PROG}")
26 | endif(LIBLAS_CONFIG_PROG)
27 |
28 |
29 | find_package_handle_standard_args(LIBLAS DEFAULT_MSG
30 | LIBLAS_INCLUDE_DIRS LIBLAS_LIBRARIES)
31 |
32 |
--------------------------------------------------------------------------------
/cmake/FindE57RefImpl.cmake:
--------------------------------------------------------------------------------
1 | # $Id: FindE57RefImpl.cmake $
2 |
3 | if (E57RefImpl_FIND_VERSION)
4 | message(WARNING "Finding a specific version of E57RefImpl is not supported.")
5 | endif (E57RefImpl_FIND_VERSION)
6 |
7 |
8 | find_package(Xerces)
9 |
10 | if(Xerces_FOUND)
11 |
12 | find_path(E57RefImpl_ROOT
13 | NAMES E57RefImplConfig.cmake
14 | PATHS /usr/local/e57 /usr/E57RefImpl
15 | )
16 |
17 |
18 | if (E57RefImpl_ROOT)
19 | set(E57RefImpl_LIBRARY_DIRS "${E57RefImpl_ROOT}/lib"
20 | ${Xerces_LIBRARY_DIRS})
21 | set(E57RefImpl_INCLUDE_DIRS "${E57RefImpl_ROOT}/include"
22 | ${Xerces_INCLUDE_DIRS})
23 | set(E57RefImpl_LIBRARIES E57RefImpl ${Xerces_LIBRARIES} ${Xerces_LIBRARY} )
24 | endif()
25 |
26 |
27 | find_package_handle_standard_args(E57RefImpl DEFAULT_MSG
28 | E57RefImpl_LIBRARY_DIRS
29 | E57RefImpl_INCLUDE_DIRS
30 | E57RefImpl_LIBRARIES)
31 | else()
32 |
33 | message(STATUS "Cannot use E57. Xerces was not found")
34 | endif()
35 |
--------------------------------------------------------------------------------
/README:
--------------------------------------------------------------------------------
1 | pcl_io_extra
2 | By Adam Stambler of Carnegie Mellon University
3 |
4 | This is a package of additional io modules for PCL.
5 | It is meant to make it easier to just take a random point cloud file
6 | and read it into your PCL program.
7 |
8 | Reader Support
9 | PTX
10 | E57
11 | LAS
12 |
13 | Write Support:
14 |
15 |
16 |
17 |
18 | --------------Library Requrements-------------------
19 |
20 | Xerces
21 | Both E57 and LAS use Xerces. You want Xerces 3.0 or greater.
22 |
23 | sudo apt-get install libxerces-c-dev
24 |
25 |
26 |
27 | LAS Support requires liblas.
28 | You can get liblas from : http://liblas.org/index.html
29 |
30 | git clone git://github.com/libLAS/libLAS.git liblas
31 |
32 | Do not use the debian install for Ubuntu
33 | The debian install on 11.10 is too old.
34 |
35 |
36 | E57
37 | E57 support depends on libe57 ( http://www.libe57.org/)
38 |
39 | You need to compile your own E57:
40 |
41 | svn co https://e57-3d-imgfmt.svn.sourceforge.net/svnroot/e57-3d-imgfmt/trunk e57refimpl
42 |
--------------------------------------------------------------------------------
/include/pcl/double_utils.h:
--------------------------------------------------------------------------------
1 | /*
2 | * double.h
3 | *
4 | * Created on: Aug 8, 2012
5 | * Author: Adam Stambler
6 | */
7 |
8 | #ifndef DOUBLE_UTILS_H_
9 | #define DOUBLE_UTILS_H_
10 |
11 | #include
12 | #include
13 |
14 | #include
15 | #include
16 |
17 | namespace pcl{
18 |
19 |
20 | bool hasDoublePointXYZ(const pcl::PCLPointCloud2& cloud);
21 |
22 |
23 | template
24 | void cvtAndOffset( const pcl::PointCloud& cloudA, const pcl::PointCloud& cloudB, Eigen::Vector3d& offset){
25 | if ( cloudB.points.size() != cloudA.points.size()){
26 | cloudB.points.resize(cloudA.size());
27 | }
28 | for(int i=0; i
12 |
13 |
14 | namespace pcl{
15 | /** \brief A point structure representing Euclidean xyz coordinates, and the intensity value.
16 | * \ingroup common
17 | */
18 | // struct Intensity
19 | // {
20 | // float intensity;
21 | // };
22 |
23 | struct PointXYZD{
24 | union {
25 | double data[3]; \
26 | struct {
27 | double x;
28 | double y;
29 | double z;
30 | };
31 | };
32 | inline Eigen::Map getVector3dMap () { return (Eigen::Vector3d::Map (data)); }
33 | inline const Eigen::Map getVector3dMap () const { return (Eigen::Vector3d::Map (data)); }
34 | };
35 | }
36 |
37 | POINT_CLOUD_REGISTER_POINT_STRUCT ( pcl::PointXYZD,
38 | (double, x, x)
39 | (double, y, y)
40 | (double, z, z)
41 | )
42 |
43 |
44 | //POINT_CLOUD_REGISTER_POINT_STRUCT ( pcl::Intensity,
45 | // (float, intensity, intensity)
46 | // )
47 |
48 |
49 |
50 | #endif /* INTENSITY_POINT_TYPE_H_ */
51 |
--------------------------------------------------------------------------------
/include/pcl/io/cloud_collection.h:
--------------------------------------------------------------------------------
1 | /*
2 | * CloudCollection.h
3 | *
4 | * Created on: Feb 21, 2012
5 | * Author: asher
6 | */
7 |
8 | #ifndef CLOUDCOLLECTION_H_
9 | #define CLOUDCOLLECTION_H_
10 |
11 | #include
12 | #include
13 | #include
14 |
15 | #include
16 | #include