40 #ifndef PCL_OCTREE_POINTCLOUD_ADJACENCY_CONTAINER_H_
41 #define PCL_OCTREE_POINTCLOUD_ADJACENCY_CONTAINER_H_
53 template<
typename Po
intInT,
typename DataT = Po
intInT>
57 typedef std::set<OctreePointCloudAdjacencyContainer*>
NeighborSetT;
59 typedef typename NeighborSetT::iterator
iterator;
66 inline size_t size ()
const {
return neighbors_.size (); }
100 using namespace pcl::common;
134 neighbors_.insert (neighbor);
143 neighbors_.erase (neighbor);
153 return neighbors_.size ();
162 neighbors_ = neighbor_arg;
173 setData (
const DataT& data_arg) { data_ = data_arg;}
Octree container class that can serve as a base to construct own leaf node container classes...
NeighborSetT::const_iterator const_iterator
virtual void reset()
Clear the voxel centroid.
Octree adjacency leaf container class- stores set of pointers to neighbors, number of points added...
void setData(const DataT &data_arg)
Sets the data member.
virtual ~OctreePointCloudAdjacencyContainer()
Empty class deconstructor.
const_iterator begin() const
virtual OctreePointCloudAdjacencyContainer * deepCopy() const
deep copy function
std::pair< iterator, bool > insert(OctreePointCloudAdjacencyContainer *neighbor)
void addPoint(const PointInT &new_point)
Add new point to container- this just counts points.
const_iterator end() const
int getPointCounter() const
Gets the number of points contributing to this leaf.
OctreePointCloudAdjacencyContainer()
Class initialization.
NeighborSetT::iterator iterator
DataT & getData()
Returns a reference to the data member to access it without copying.
void setNeighbors(const NeighborSetT &neighbor_arg)
Sets the whole neighbor set.
void addNeighbor(OctreePointCloudAdjacencyContainer *neighbor)
Add new neighbor to voxel.
void setPointCounter(int points_arg)
Sets the number of points contributing to this leaf.
size_t getNumNeighbors() const
Returns the number of neighbors this leaf has.
void computeData()
Function for working on data added.
virtual size_t getSize()
virtual method to get size of container
void removeNeighbor(OctreePointCloudAdjacencyContainer *neighbor)
Remove neighbor from neighbor set.
std::set< OctreePointCloudAdjacencyContainer * > NeighborSetT