40 #ifndef PCL_OCTREE_POINTCLOUD_ADJACENCY_H_
41 #define PCL_OCTREE_POINTCLOUD_ADJACENCY_H_
43 #include <pcl/common/geometry.h>
44 #include <pcl/octree/boost.h>
45 #include <pcl/octree/octree_base.h>
46 #include <pcl/octree/octree_iterator.h>
47 #include <pcl/octree/octree_pointcloud.h>
48 #include <pcl/octree/octree_pointcloud_adjacency_container.h>
54 #include <pcl/common/time.h>
81 typename LeafContainerT = OctreePointCloudAdjacencyContainer <PointT>,
82 typename BranchContainerT = OctreeContainerEmpty >
91 typedef boost::shared_ptr<OctreeAdjacencyT>
Ptr;
92 typedef boost::shared_ptr<const OctreeAdjacencyT>
ConstPtr;
122 typedef boost::adjacency_list<boost::setS, boost::setS, boost::undirectedS, PointT, float>
VoxelAdjacencyList;
123 typedef typename VoxelAdjacencyList::vertex_descriptor
VoxelID;
124 typedef typename VoxelAdjacencyList::edge_descriptor
EdgeID;
134 inline size_t size ()
const {
return leaf_vector_.size (); }
176 transform_func_ = transform_func;
217 boost::function<void (PointT &p)> transform_func_;
233 #include <pcl/octree/impl/octree_pointcloud_adjacency.hpp>
236 #endif //PCL_OCTREE_POINTCLOUD_SUPER_VOXEL_H_
boost::adjacency_list< boost::setS, boost::setS, boost::undirectedS, PointT, float > VoxelAdjacencyList
VoxelAdjacencyList::vertex_descriptor VoxelID
OctreePointCloudAdjacency(const double resolution_arg)
Constructor.
OctreePointCloudT::LeafNode LeafNode
OctreePointCloudT::BranchNode BranchNode
LeafVectorT::const_iterator const_iterator
OctreeBase< LeafContainerT, BranchContainerT > OctreeBaseT
Octree pointcloud voxel class used for adjacency calculation
LeafNodeIterator leaf_begin(unsigned int maxDepth_arg=0)
VoxelAdjacencyList::edge_descriptor EdgeID
const OctreeLeafNodeIterator< OctreeAdjacencyT > ConstLeafNodeIterator
OctreeLeafNodeIterator< OctreeAdjacencyT > LeafNodeIterator
virtual ~OctreePointCloudAdjacency()
Empty class destructor.
bool testForOcclusion(const PointT &point_arg, const PointXYZ &camera_pos=PointXYZ(0, 0, 0))
Tests whether input point is occluded from specified camera point by other voxels.
boost::shared_ptr< OctreeAdjacencyT > Ptr
boost::shared_ptr< const OctreeAdjacencyT > ConstPtr
std::vector< LeafContainerT * > LeafVectorT
void addPointsFromInputCloud()
Adds points from cloud to the octree.
double resolution_
Octree resolution.
virtual void addPointIdx(const int pointIdx_arg)
Add point at index from input pointcloud dataset to octree.
OctreePointCloud< PointT, LeafContainerT, BranchContainerT, OctreeBaseT > OctreePointCloudT
OctreeT::BranchNode BranchNode
OctreePointCloudAdjacency< PointT, LeafContainerT, BranchContainerT > OctreeAdjacencyT
const LeafNodeIterator leaf_end()
OctreeT::LeafNode LeafNode
pcl::PointCloud< PointT > CloudT
void genOctreeKeyforPoint(const PointT &point_arg, OctreeKey &key_arg) const
Generates octree key for specified point (uses transform if provided)
Abstract octree iterator class
const OctreeDepthFirstIterator< OctreeAdjacencyT > ConstIterator
const Iterator depth_end()
LeafVectorT::iterator iterator
Octree leaf node iterator class.
void computeVoxelAdjacencyGraph(VoxelAdjacencyList &voxel_adjacency_graph)
Computes an adjacency graph of voxel relations.
void computeNeighbors(OctreeKey &key_arg, LeafContainerT *leaf_container)
Fills in the neighbors fields for new voxels.
LeafContainerT * getLeafContainerAtPoint(const PointT &point_arg) const
Gets the leaf container for a given point.
A point structure representing Euclidean xyz coordinates.
void setTransformFunction(boost::function< void(PointT &p)> transform_func)
Sets a point transform (and inverse) used to transform the space of the input cloud This is useful fo...
OctreeDepthFirstIterator< OctreeAdjacencyT > Iterator
A point structure representing Euclidean xyz coordinates, and the RGB color.
Iterator depth_begin(unsigned int maxDepth_arg=0)
PointCloudConstPtr input_
Pointer to input point cloud dataset.