Skip to content

Commit

Permalink
Optimize includes
Browse files Browse the repository at this point in the history
  • Loading branch information
mvieth committed Jan 23, 2022
1 parent c034495 commit 292593a
Show file tree
Hide file tree
Showing 19 changed files with 35 additions and 28 deletions.
1 change: 1 addition & 0 deletions apps/include/pcl/apps/nn_classification.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@
#include <pcl/kdtree/kdtree_flann.h>

#include <limits>
#include <map> // for std::map

namespace pcl {

Expand Down
1 change: 0 additions & 1 deletion apps/src/openni_grab_images.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@
#include <pcl/io/pcd_io.h>
#include <pcl/visualization/common/float_image_utils.h>
#include <pcl/visualization/image_viewer.h>
#include <pcl/visualization/vtk.h>
#include <pcl/point_types.h>

#include <boost/filesystem.hpp>
Expand Down
1 change: 0 additions & 1 deletion common/include/pcl/common/impl/io.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@
#include <pcl/common/concatenate.h>
#include <pcl/common/copy_point.h>
#include <pcl/common/io.h>
#include <pcl/point_types.h>


namespace pcl
Expand Down
1 change: 0 additions & 1 deletion common/include/pcl/common/transforms.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
#pragma once

#include <pcl/point_cloud.h>
#include <pcl/point_types.h>
#include <pcl/common/centroid.h>
#include <pcl/common/eigen.h>
#include <pcl/PointIndices.h>
Expand Down
2 changes: 0 additions & 2 deletions common/include/pcl/conversions.h
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,6 @@
#include <pcl/for_each_type.h>
#include <pcl/console/print.h>

#include <boost/foreach.hpp>

namespace pcl
{
namespace detail
Expand Down
1 change: 1 addition & 0 deletions features/src/narf.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
#include <iostream>
#include <fstream>
#include <cmath>
#include <map> // for std::multimap
using std::cout;
using std::cerr;
using std::vector;
Expand Down
17 changes: 1 addition & 16 deletions io/include/pcl/io/vtk_lib_io.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@

#pragma once

#include <pcl/point_types.h>
#include <pcl/point_cloud.h>
#include <pcl/PolygonMesh.h>
#include <pcl/TextureMesh.h>
Expand All @@ -52,23 +51,9 @@
#ifdef __GNUC__
#pragma GCC system_header
#endif
#include <vtkPolyData.h> // for vtkPolyData
#include <vtkSmartPointer.h>
#include <vtkStructuredGrid.h>
#include <vtkPoints.h>
#include <vtkPointData.h>
#include <vtkCellArray.h>
#include <vtkUnsignedCharArray.h>
#include <vtkFloatArray.h>
#include <vtkPolyDataReader.h>
#include <vtkPolyDataWriter.h>
#include <vtkPLYReader.h>
#include <vtkPLYWriter.h>
#include <vtkOBJReader.h>
#include <vtkSTLReader.h>
#include <vtkSTLWriter.h>
#include <vtkPNGReader.h>
#include <vtkImageData.h>
#include <vtkPolyDataNormals.h>

namespace pcl
{
Expand Down
13 changes: 11 additions & 2 deletions io/src/vtk_lib_io.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,19 @@
#include <pcl/PCLPointCloud2.h>
#include <vtkCellArray.h>
#include <vtkCellData.h>
#include <vtkDoubleArray.h>
#include <vtkFloatArray.h> // for vtkFloatArray
#include <vtkImageData.h>
#include <vtkImageShiftScale.h>
#include <vtkPNGWriter.h>
#include <vtkOBJReader.h> // for vtkOBJReader
#include <vtkPoints.h> // for vtkPoints
#include <vtkPolyDataReader.h> // for vtkPolyDataReader
#include <vtkPolyDataWriter.h> // for vtkPolyDataWriter
#include <vtkPLYReader.h> // for vtkPLYReader
#include <vtkPLYWriter.h> // for vtkPLYWriter
#include <vtkPNGWriter.h> // for vtkPNGWriter
#include <vtkSTLReader.h> // for vtkSTLReader
#include <vtkSTLWriter.h> // for vtkSTLWriter
#include <vtkUnsignedCharArray.h> // for vtkUnsignedCharArray

// Support for VTK 7.1 upwards
#ifdef vtkGenericDataArray_h
Expand Down
3 changes: 0 additions & 3 deletions io/tools/openni_grabber_depth_example.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,6 @@
*
*/

#include <pcl/point_cloud.h>
#include <pcl/point_types.h>
#include <pcl/io/pcd_io.h>
#include <pcl/io/openni_grabber.h>
#include <pcl/common/time.h>
#include <pcl/console/parse.h>
Expand Down
2 changes: 2 additions & 0 deletions octree/include/pcl/octree/octree_key.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@

#pragma once

#include <pcl/types.h> // for uindex_t

#include <cstdint>
#include <cstring> // for memcpy

Expand Down
2 changes: 2 additions & 0 deletions registration/include/pcl/registration/impl/ndt_2d.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@
#ifndef PCL_NDT_2D_IMPL_H_
#define PCL_NDT_2D_IMPL_H_

#include <boost/core/noncopyable.hpp> // for boost::noncopyable

#include <Eigen/Eigenvalues> // for SelfAdjointEigenSolver, EigenSolver

#include <cmath>
Expand Down
1 change: 0 additions & 1 deletion stereo/src/stereo_grabber.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@

#include <pcl/stereo/stereo_grabber.h>
#include <pcl/PCLPointCloud2.h> // for PCLPointCloud2
#include <pcl/point_types.h>

///////////////////////////////////////////////////////////////////////////////////////////
//////////////////////// GrabberImplementation //////////////////////
Expand Down
1 change: 0 additions & 1 deletion test/io/test_octree_compression.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@
#include <pcl/test/gtest.h>
#include <pcl/point_cloud.h>
#include <pcl/point_types.h>
#include <pcl/octree/octree.h>
#include <pcl/io/pcd_io.h>
#include <pcl/compression/octree_pointcloud_compression.h>
#include <pcl/compression/compression_profiles.h>
Expand Down
3 changes: 3 additions & 0 deletions tools/obj2pcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@
#include <pcl/console/parse.h>
#include <pcl/console/time.h>

#include <vtkOBJReader.h> // for vtkOBJReader
#include <vtkPolyDataNormals.h> // vtkPolyDataNormals

using namespace pcl;
using namespace pcl::io;
using namespace pcl::console;
Expand Down
3 changes: 3 additions & 0 deletions tools/obj2vtk.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@
#include <pcl/console/parse.h>
#include <pcl/io/vtk_lib_io.h>

#include <vtkOBJReader.h> // for vtkOBJReader
#include <vtkPolyDataWriter.h> // for vtkPolyDataWriter

using namespace pcl;
using namespace pcl::io;
using namespace pcl::console;
Expand Down
3 changes: 3 additions & 0 deletions tools/ply2vtk.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@
#include <pcl/console/parse.h>
#include <pcl/io/vtk_lib_io.h>

#include <vtkPLYReader.h> // for vtkPLYReader
#include <vtkPolyDataWriter.h> // for vtkPolyDataWriter

using namespace pcl;
using namespace pcl::io;
using namespace pcl::console;
Expand Down
2 changes: 2 additions & 0 deletions tools/virtual_scanner.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,8 @@

#include <vtkGeneralTransform.h>
#include <vtkPlatonicSolidSource.h>
#include <vtkPolyDataReader.h> // for vtkPolyDataReader
#include <vtkPLYReader.h> // for vtkPLYReader
#include <vtkLoopSubdivisionFilter.h>
#include <vtkCellLocator.h>
#include <vtkMath.h>
Expand Down
3 changes: 3 additions & 0 deletions tools/vtk2pcd.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,9 @@
#include <pcl/console/parse.h>
#include <pcl/console/time.h>

#include <vtkPolyDataNormals.h> // for vtkPolyDataNormals
#include <vtkPolyDataReader.h> // for vtkPolyDataReader

using namespace pcl;
using namespace pcl::io;
using namespace pcl::console;
Expand Down
3 changes: 3 additions & 0 deletions tools/vtk2ply.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,9 @@
#include <pcl/console/parse.h>
#include <pcl/io/vtk_lib_io.h>

#include <vtkPolyDataReader.h> // for vtkPolyDataReader
#include <vtkPLYWriter.h> // for vtkPLYWriter

using namespace pcl;
using namespace pcl::io;
using namespace pcl::console;
Expand Down

0 comments on commit 292593a

Please sign in to comment.