Ponca  aa50bfdf187919869239c5b44b748842569114c1
Point Cloud Analysis library
Loading...
Searching...
No Matches
Ponca::KdTreeDefaultTraits< _DataPoint, _NodeType > Struct Template Reference

The default traits type used by the kd-tree. More...

#include <kdTreeTraits.h>

+ Collaboration diagram for Ponca::KdTreeDefaultTraits< _DataPoint, _NodeType >:

Public Types

enum  { MAX_DEPTH = 32 }
 
using DataPoint = _DataPoint
 The type used to store point data.
 
using IndexType = int
 
using LeafSizeType = unsigned short
 
using PointContainer = std::vector< DataPoint >
 
using IndexContainer = std::vector< IndexType >
 
using NodeIndexType = std::size_t
 
using NodeType = _NodeType< IndexType, NodeIndexType, DataPoint, LeafSizeType >
 
using NodeContainer = std::vector< NodeType >
 

Detailed Description

template<typename _DataPoint, template< typename, typename, typename, typename > typename _NodeType = KdTreeDefaultNode>
struct Ponca::KdTreeDefaultTraits< _DataPoint, _NodeType >

The default traits type used by the kd-tree.

See also
KdTreeCustomizableNode Helper class to modify Inner/Leaf nodes without redefining a Trait class
Template Parameters
_NodeTypeType used to store nodes, set by default to #KdTreeDefaultNode

Definition at line 251 of file kdTreeTraits.h.

Member Typedef Documentation

◆ DataPoint

template<typename _DataPoint , template< typename, typename, typename, typename > typename _NodeType = KdTreeDefaultNode>
using Ponca::KdTreeDefaultTraits< _DataPoint, _NodeType >::DataPoint = _DataPoint

The type used to store point data.

Must provide Scalar and VectorType typedefs.

VectorType must provide a squaredNorm() function returning a Scalar, as well as a maxCoeff(int*) function returning the dimension index of its largest scalar in its output parameter (e.g. 0 for x, 1 for y, etc.).

Definition at line 270 of file kdTreeTraits.h.

◆ IndexContainer

template<typename _DataPoint , template< typename, typename, typename, typename > typename _NodeType = KdTreeDefaultNode>
using Ponca::KdTreeDefaultTraits< _DataPoint, _NodeType >::IndexContainer = std::vector<IndexType>

Definition at line 276 of file kdTreeTraits.h.

◆ IndexType

template<typename _DataPoint , template< typename, typename, typename, typename > typename _NodeType = KdTreeDefaultNode>
using Ponca::KdTreeDefaultTraits< _DataPoint, _NodeType >::IndexType = int

Definition at line 271 of file kdTreeTraits.h.

◆ LeafSizeType

template<typename _DataPoint , template< typename, typename, typename, typename > typename _NodeType = KdTreeDefaultNode>
using Ponca::KdTreeDefaultTraits< _DataPoint, _NodeType >::LeafSizeType = unsigned short

Definition at line 272 of file kdTreeTraits.h.

◆ NodeContainer

template<typename _DataPoint , template< typename, typename, typename, typename > typename _NodeType = KdTreeDefaultNode>
using Ponca::KdTreeDefaultTraits< _DataPoint, _NodeType >::NodeContainer = std::vector<NodeType>

Definition at line 281 of file kdTreeTraits.h.

◆ NodeIndexType

template<typename _DataPoint , template< typename, typename, typename, typename > typename _NodeType = KdTreeDefaultNode>
using Ponca::KdTreeDefaultTraits< _DataPoint, _NodeType >::NodeIndexType = std::size_t

Definition at line 279 of file kdTreeTraits.h.

◆ NodeType

template<typename _DataPoint , template< typename, typename, typename, typename > typename _NodeType = KdTreeDefaultNode>
using Ponca::KdTreeDefaultTraits< _DataPoint, _NodeType >::NodeType = _NodeType<IndexType, NodeIndexType, DataPoint, LeafSizeType>

Definition at line 280 of file kdTreeTraits.h.

◆ PointContainer

template<typename _DataPoint , template< typename, typename, typename, typename > typename _NodeType = KdTreeDefaultNode>
using Ponca::KdTreeDefaultTraits< _DataPoint, _NodeType >::PointContainer = std::vector<DataPoint>

Definition at line 275 of file kdTreeTraits.h.

Member Enumeration Documentation

◆ anonymous enum

template<typename _DataPoint , template< typename, typename, typename, typename > typename _NodeType = KdTreeDefaultNode>
anonymous enum
Enumerator
MAX_DEPTH 

A compile-time constant specifying the maximum depth of the kd-tree.

Definition at line 253 of file kdTreeTraits.h.