|
Ponca
eff04be8be0ed1ccd36b694a34ae55d988e046fb
Point Cloud Analysis library
|
Customizable static base class for KdTree datastructure implementations. More...
#include <kdTree.h>
Inheritance diagram for Ponca::StaticKdTreeBase< Traits >:
Collaboration diagram for Ponca::StaticKdTreeBase< Traits >:Classes | |
| struct | Buffers |
| Internal structure storing all the buffers used by the KdTree. More... | |
Public Types | |
| using | DataPoint = typename Traits::DataPoint |
| DataPoint given by user via Traits | |
| using | IndexType = typename Traits::IndexType |
| Type used to index points into the PointContainer | |
| using | LeafSizeType = typename Traits::LeafSizeType |
| Type used to store the size of leaf nodes | |
| using | PointContainer = typename Traits::PointContainer |
| Container for DataPoint used inside the KdTree | |
| using | IndexContainer = typename Traits::IndexContainer |
| Container for indices used inside the KdTree | |
| using | NodeIndexType = typename Traits::NodeIndexType |
| Type used to index nodes into the NodeContainer | |
| using | NodeType = typename Traits::NodeType |
| Type of nodes used inside the KdTree | |
| using | NodeContainer = typename Traits::NodeContainer |
| Container for nodes used inside the KdTree | |
| using | Scalar = typename DataPoint::Scalar |
| Scalar given by user via DataPoint | |
| using | VectorType = typename DataPoint::VectorType |
| VectorType given by user via DataPoint | |
| using | AabbType = typename NodeType::AabbType |
| Bounding box type given by user via NodeType | |
Public Member Functions | |
| StaticKdTreeBase (Buffers &buf) | |
| Constructor that allows the use of prebuilt KdTree containers. | |
| NodeIndexType | nodeCount () const |
| Get the number of nodes in the KdTree. | |
| IndexType | sampleCount () const |
| Get the number of indices. | |
| IndexType | pointCount () const |
| Get the number of points. | |
| NodeIndexType | leafCount () const |
| Get the number of leafs in the KdTree. | |
| PointContainer & | points () |
| Get the internal point container. | |
| const PointContainer & | points () const |
| Get the internal point container. | |
| const NodeContainer & | nodes () const |
| Get the internal node container. | |
| const IndexContainer & | samples () const |
| Get the internal indice container. | |
| const Buffers & | buffers () const |
| Get access to the internal buffer, for instance to prepare GPU binding. | |
| LeafSizeType | minCellSize () const |
| Read leaf min size. | |
| void | setMinCellSize (LeafSizeType min_cell_size) |
| Write leaf min size. | |
| IndexType | pointFromSample (IndexType sample_index) const |
| Return the point index associated with the specified sample index. | |
| DataPoint & | pointDataFromSample (IndexType sample_index) |
| Return the DataPoint associated with the specified sample index. | |
| const DataPoint & | pointDataFromSample (IndexType sample_index) const |
| Return the DataPoint associated with the specified sample index. | |
| KdTreeKNearestPointQuery< Traits > | kNearestNeighbors (const VectorType &point, IndexType k) const |
| Computes a Query object to iterate over the k-nearest neighbors of a point. The returned object can be reset and reused with the () operator (using the same argument types as parameters). | |
| KdTreeKNearestIndexQuery< Traits > | kNearestNeighbors (IndexType index, IndexType k) const |
| Computes a Query object to iterate over the k-nearest neighbors of a point. The returned object can be reset and reused with the () operator (using the same argument types as parameters). | |
| KdTreeKNearestPointQuery< Traits > | kNearestNeighborsQuery () const |
| Convenience function that provides an empty k-nearest neighbors Query object. | |
| KdTreeKNearestIndexQuery< Traits > | kNearestNeighborsIndexQuery () const |
| Convenience function that provides an empty k-nearest neighbors Query object. | |
| KdTreeNearestPointQuery< Traits > | nearestNeighbor (const VectorType &point) const |
| Computes a Query object that contains the nearest point. The returned object can be reset and reused with the () operator (using the same argument types as parameters). | |
| KdTreeNearestIndexQuery< Traits > | nearestNeighbor (IndexType index) const |
| Computes a Query object that contains the nearest point. The returned object can be reset and reused with the () operator (using the same argument types as parameters). | |
| KdTreeNearestIndexQuery< Traits > | nearestNeighborQuery () const |
| Convenience function that provides an empty nearest neighbor Query object. | |
| KdTreeNearestIndexQuery< Traits > | nearestNeighborIndexQuery () const |
| Convenience function that provides an empty nearest neighbor Query object. | |
| KdTreeRangePointQuery< Traits > | rangeNeighbors (const VectorType &point, Scalar r) const |
| Computes a Query object to iterate over the neighbors that are inside a given radius. The returned object can be reset and reused with the () operator (using the same argument types as parameters). | |
| KdTreeRangeIndexQuery< Traits > | rangeNeighbors (IndexType index, Scalar r) const |
| Computes a Query object to iterate over the neighbors that are inside a given radius. The returned object can be reset and reused with the () operator (using the same argument types as parameters). | |
| KdTreeRangePointQuery< Traits > | rangeNeighborsQuery () const |
| Convenience function that provides an empty range neighbor Query object. | |
| KdTreeRangeIndexQuery< Traits > | rangeNeighborsIndexQuery () const |
| KdTreeBase::rangeNeighborsQuery. | |
| bool | valid () const |
| void | print (std::ostream &os, bool verbose=false) const |
Static Public Attributes | |
| static constexpr std::size_t | MAX_NODE_COUNT = NodeType::MAX_COUNT |
| The maximum number of nodes that the kd-tree can have. | |
| static constexpr std::size_t | MAX_POINT_COUNT = std::size_t(2) << sizeof(IndexType)*8 |
| The maximum number of points that can be stored in the kd-tree. | |
| static constexpr int | MAX_DEPTH = Traits::MAX_DEPTH |
| The maximum depth of the kd-tree. | |
| static constexpr bool | SUPPORTS_SUBSAMPLING = false |
Protected Attributes | |
| Buffers | m_bufs |
| Buffers used to store the KdTree. | |
| LeafSizeType | m_min_cell_size {64} |
| Minimal number of points per leaf. | |
| NodeIndexType | m_leaf_count {0} |
| Number of leaves in the Kdtree (computed during construction) | |
Customizable static base class for KdTree datastructure implementations.
| Traits | Traits type providing the types and constants used by the kd-tree. Must have the same interface as the default traits type. |
| using Ponca::StaticKdTreeBase< Traits >::AabbType = typename NodeType::AabbType |
| using Ponca::StaticKdTreeBase< Traits >::DataPoint = typename Traits::DataPoint |
| using Ponca::StaticKdTreeBase< Traits >::IndexContainer = typename Traits::IndexContainer |
| using Ponca::StaticKdTreeBase< Traits >::IndexType = typename Traits::IndexType |
| using Ponca::StaticKdTreeBase< Traits >::LeafSizeType = typename Traits::LeafSizeType |
| using Ponca::StaticKdTreeBase< Traits >::NodeContainer = typename Traits::NodeContainer |
| using Ponca::StaticKdTreeBase< Traits >::NodeIndexType = typename Traits::NodeIndexType |
| using Ponca::StaticKdTreeBase< Traits >::NodeType = typename Traits::NodeType |
| using Ponca::StaticKdTreeBase< Traits >::PointContainer = typename Traits::PointContainer |
| using Ponca::StaticKdTreeBase< Traits >::Scalar = typename DataPoint::Scalar |
| using Ponca::StaticKdTreeBase< Traits >::VectorType = typename DataPoint::VectorType |
|
inline |
Constructor that allows the use of prebuilt KdTree containers.
Each internal values of a KdTree can be extracted using `KdTreeBasebuffers()`
| buf | Internal buffers of the KdTree |
|
inline |
|
inline |
Computes a Query object to iterate over the k-nearest neighbors of a point. The returned object can be reset and reused with the () operator (using the same argument types as parameters).
| point | Point from where the query is evaluated |
| k | Number of neighbors returned |
|
inline |
Computes a Query object to iterate over the k-nearest neighbors of a point. The returned object can be reset and reused with the () operator (using the same argument types as parameters).
| index | Index of the point from where the query is evaluated |
| k | Number of neighbors returned |
|
inline |
Convenience function that provides an empty k-nearest neighbors Query object.
The returned object can call for a k-nearest neighbors search using the operator (), which takes a k and an index as parameters.
Same as KdTreeBase::kNearestNeighbors (0, 0)
|
inline |
Convenience function that provides an empty k-nearest neighbors Query object.
The returned object can call for a k-nearest neighbors search using the operator (), which takes a k and a position as parameters.
Same as KdTreeBase::kNearestNeighbors (0, VectorType::Zero())
|
inline |
|
inline |
|
inline |
Computes a Query object that contains the nearest point. The returned object can be reset and reused with the () operator (using the same argument types as parameters).
| point | Point from where the query is evaluated |
|
inline |
Computes a Query object that contains the nearest point. The returned object can be reset and reused with the () operator (using the same argument types as parameters).
| index | Index of the point from where the query is evaluated |
|
inline |
Convenience function that provides an empty nearest neighbor Query object.
The returned object can call for a nearest neighbor search using the operator (), which takes an index as parameter.
Same as KdTreeBase::nearestNeighbor (0)
|
inline |
Convenience function that provides an empty nearest neighbor Query object.
The returned object can call for a nearest neighbor search using the operator (), which takes a position as parameter.
Same as KdTreeBase::nearestNeighbor (VectorType::Zero())
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Definition at line 72 of file kdTree.hpp.
|
inline |
Computes a Query object to iterate over the neighbors that are inside a given radius. The returned object can be reset and reused with the () operator (using the same argument types as parameters).
| point | Point from where the query is evaluated |
| r | Radius around where to search the neighbors |
|
inline |
Computes a Query object to iterate over the neighbors that are inside a given radius. The returned object can be reset and reused with the () operator (using the same argument types as parameters).
| index | Index of the point from where the query is evaluated |
| r | Radius around where to search the neighbors |
|
inline |
KdTreeBase::rangeNeighborsQuery.
The returned object can call for a range neighbor search using the operator (), which takes an index as parameter.
Same as KdTreeBase::rangeNeighborsQuery (0, 0)
|
inline |
Convenience function that provides an empty range neighbor Query object.
The returned object can call for a range neighbor search using the operator (), which takes a position as parameter.
Same as KdTreeBase::rangeNeighborsQuery (0, VectorType::Zero())
|
inline |
|
inline |
|
inline |
|
inline |
Definition at line 19 of file kdTree.hpp.
|
protected |
|
protected |
|
protected |
|
staticconstexpr |
|
staticconstexpr |
|
staticconstexpr |
|
staticconstexpr |