ITK  6.0.0
Insight Toolkit
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | Protected Member Functions | Private Attributes | List of all members
itk::PointsLocator< TPointsContainer > Class Template Reference

#include <itkPointsLocator.h>

Detailed Description

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
class itk::PointsLocator< TPointsContainer >

Accelerate geometric searches for points.

This class accelerates the search for the closest point to a user-provided point, by using constructing a Kd-Tree structure for the PointSetContainer.

Definition at line 42 of file itkPointsLocator.h.

+ Inheritance diagram for itk::PointsLocator< TPointsContainer >:
+ Collaboration diagram for itk::PointsLocator< TPointsContainer >:

Public Types

using ConstPointer = SmartPointer< const Self >
 
using NeighborsIdentifierType = typename TreeType::InstanceIdentifierVectorType
 
using Pointer = SmartPointer< Self >
 
using PointIdentifier = typename PointsContainer::ElementIdentifier
 
using PointsContainer = TPointsContainer
 
using PointsContainerConstIterator = typename PointsContainer::ConstIterator
 
using PointsContainerConstPointer = typename PointsContainer::ConstPointer
 
using PointsContainerIterator = typename PointsContainer::Iterator
 
using PointsContainerPointer = typename PointsContainer::Pointer
 
using PointType = typename PointsContainer::Element
 
using SampleAdaptorPointer = typename SampleAdaptorType::Pointer
 
using SampleAdaptorType = Statistics::VectorContainerToListSampleAdaptor< PointsContainer >
 
using Self = PointsLocator
 
using Superclass = Object
 
using TreeConstPointer = typename TreeType::ConstPointer
 
using TreeGeneratorPointer = typename TreeGeneratorType::Pointer
 
using TreeGeneratorType = Statistics::KdTreeGenerator< SampleAdaptorType >
 
using TreeType = typename TreeGeneratorType::KdTreeType
 
- Public Types inherited from itk::Object
using ConstPointer = SmartPointer< const Self >
 
using Pointer = SmartPointer< Self >
 
using Self = Object
 
using Superclass = LightObject
 
- Public Types inherited from itk::LightObject
using ConstPointer = SmartPointer< const Self >
 
using Pointer = SmartPointer< Self >
 
using Self = LightObject
 

Public Member Functions

void FindClosestNPoints (const PointType &, unsigned int, NeighborsIdentifierType &) const
 
void FindClosestNPoints (const PointType &, unsigned int, NeighborsIdentifierType &, std::vector< double > &) const
 
PointIdentifier FindClosestPoint (const PointType &query) const
 
void FindPointsWithinRadius (const PointType &, double, NeighborsIdentifierType &) const
 
virtual PointsContainerGetModifiablePoints ()
 
const char * GetNameOfClass () const override
 
void Initialize ()
 
virtual void SetPoints (PointsContainer *_arg)
 
- Public Member Functions inherited from itk::Object
unsigned long AddObserver (const EventObject &event, Command *cmd) const
 
unsigned long AddObserver (const EventObject &event, std::function< void(const EventObject &)> function) const
 
LightObject::Pointer CreateAnother () const override
 
virtual void DebugOff () const
 
virtual void DebugOn () const
 
CommandGetCommand (unsigned long tag)
 
bool GetDebug () const
 
MetaDataDictionaryGetMetaDataDictionary ()
 
const MetaDataDictionaryGetMetaDataDictionary () const
 
virtual ModifiedTimeType GetMTime () const
 
const char * GetNameOfClass () const override
 
virtual const TimeStampGetTimeStamp () const
 
bool HasObserver (const EventObject &event) const
 
void InvokeEvent (const EventObject &)
 
void InvokeEvent (const EventObject &) const
 
virtual void Modified () const
 
void Register () const override
 
void RemoveAllObservers ()
 
void RemoveObserver (unsigned long tag) const
 
void SetDebug (bool debugFlag) const
 
void SetReferenceCount (int) override
 
void UnRegister () const noexcept override
 
void SetMetaDataDictionary (const MetaDataDictionary &rhs)
 
void SetMetaDataDictionary (MetaDataDictionary &&rrhs)
 
virtual void SetObjectName (std::string _arg)
 
virtual const std::string & GetObjectName () const
 
- Public Member Functions inherited from itk::LightObject
Pointer Clone () const
 
virtual Pointer CreateAnother () const
 
virtual void Delete ()
 
virtual const char * GetNameOfClass () const
 
virtual int GetReferenceCount () const
 
void Print (std::ostream &os, Indent indent=0) const
 
virtual void Register () const
 
virtual void SetReferenceCount (int)
 
virtual void UnRegister () const noexcept
 

Static Public Member Functions

static Pointer New ()
 
- Static Public Member Functions inherited from itk::Object
static bool GetGlobalWarningDisplay ()
 
static void GlobalWarningDisplayOff ()
 
static void GlobalWarningDisplayOn ()
 
static Pointer New ()
 
static void SetGlobalWarningDisplay (bool val)
 
- Static Public Member Functions inherited from itk::LightObject
static void BreakOnError ()
 
static Pointer New ()
 

Static Public Attributes

static constexpr unsigned int PointDimension = PointType::PointDimension
 

Protected Member Functions

 PointsLocator ()
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
 ~PointsLocator () override=default
 
- Protected Member Functions inherited from itk::Object
 Object ()
 
bool PrintObservers (std::ostream &os, Indent indent) const
 
void PrintSelf (std::ostream &os, Indent indent) const override
 
virtual void SetTimeStamp (const TimeStamp &timeStamp)
 
 ~Object () override
 
- Protected Member Functions inherited from itk::LightObject
virtual LightObject::Pointer InternalClone () const
 
 LightObject ()
 
virtual void PrintHeader (std::ostream &os, Indent indent) const
 
virtual void PrintSelf (std::ostream &os, Indent indent) const
 
virtual void PrintTrailer (std::ostream &os, Indent indent) const
 
virtual ~LightObject ()
 

Private Attributes

TreeGeneratorPointer m_KdTreeGenerator {}
 
PointsContainerPointer m_Points {}
 
SampleAdaptorPointer m_SampleAdaptor {}
 
TreeConstPointer m_Tree {}
 

Additional Inherited Members

- Protected Attributes inherited from itk::LightObject
std::atomic< int > m_ReferenceCount {}
 

Member Typedef Documentation

◆ ConstPointer

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::ConstPointer = SmartPointer<const Self>

Definition at line 51 of file itkPointsLocator.h.

◆ NeighborsIdentifierType

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::NeighborsIdentifierType = typename TreeType::InstanceIdentifierVectorType

Definition at line 82 of file itkPointsLocator.h.

◆ Pointer

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::Pointer = SmartPointer<Self>

Definition at line 50 of file itkPointsLocator.h.

◆ PointIdentifier

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::PointIdentifier = typename PointsContainer::ElementIdentifier

Definition at line 63 of file itkPointsLocator.h.

◆ PointsContainer

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::PointsContainer = TPointsContainer

Hold on to the type information specified by the template parameters.

Definition at line 60 of file itkPointsLocator.h.

◆ PointsContainerConstIterator

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::PointsContainerConstIterator = typename PointsContainer::ConstIterator

Convenient type alias.

Definition at line 70 of file itkPointsLocator.h.

◆ PointsContainerConstPointer

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::PointsContainerConstPointer = typename PointsContainer::ConstPointer

Definition at line 62 of file itkPointsLocator.h.

◆ PointsContainerIterator

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::PointsContainerIterator = typename PointsContainer::Iterator

Definition at line 71 of file itkPointsLocator.h.

◆ PointsContainerPointer

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::PointsContainerPointer = typename PointsContainer::Pointer

Definition at line 61 of file itkPointsLocator.h.

◆ PointType

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::PointType = typename PointsContainer::Element

Definition at line 64 of file itkPointsLocator.h.

◆ SampleAdaptorPointer

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::SampleAdaptorPointer = typename SampleAdaptorType::Pointer

Definition at line 75 of file itkPointsLocator.h.

◆ SampleAdaptorType

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::SampleAdaptorType = Statistics::VectorContainerToListSampleAdaptor<PointsContainer>

Type of the PointsContainer to List Adaptor.

Definition at line 74 of file itkPointsLocator.h.

◆ Self

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::Self = PointsLocator

Standard class type aliases.

Definition at line 48 of file itkPointsLocator.h.

◆ Superclass

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::Superclass = Object

Definition at line 49 of file itkPointsLocator.h.

◆ TreeConstPointer

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::TreeConstPointer = typename TreeType::ConstPointer

Definition at line 81 of file itkPointsLocator.h.

◆ TreeGeneratorPointer

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::TreeGeneratorPointer = typename TreeGeneratorType::Pointer

Definition at line 79 of file itkPointsLocator.h.

◆ TreeGeneratorType

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::TreeGeneratorType = Statistics::KdTreeGenerator<SampleAdaptorType>

Types fo the KdTreeGenerator

Definition at line 78 of file itkPointsLocator.h.

◆ TreeType

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
using itk::PointsLocator< TPointsContainer >::TreeType = typename TreeGeneratorType::KdTreeType

Definition at line 80 of file itkPointsLocator.h.

Constructor & Destructor Documentation

◆ PointsLocator()

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
itk::PointsLocator< TPointsContainer >::PointsLocator ( )
protected

◆ ~PointsLocator()

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
itk::PointsLocator< TPointsContainer >::~PointsLocator ( )
overrideprotecteddefault

Member Function Documentation

◆ FindClosestNPoints() [1/2]

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
void itk::PointsLocator< TPointsContainer >::FindClosestNPoints ( const PointType ,
unsigned int  ,
NeighborsIdentifierType  
) const

Find the closest N points. Returns the point ids.

◆ FindClosestNPoints() [2/2]

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
void itk::PointsLocator< TPointsContainer >::FindClosestNPoints ( const PointType ,
unsigned int  ,
NeighborsIdentifierType ,
std::vector< double > &   
) const

Find the closest N points. Returns the point ids and save the distances

◆ FindClosestPoint()

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
PointIdentifier itk::PointsLocator< TPointsContainer >::FindClosestPoint ( const PointType query) const

Find the closest point

◆ FindPointsWithinRadius()

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
void itk::PointsLocator< TPointsContainer >::FindPointsWithinRadius ( const PointType ,
double  ,
NeighborsIdentifierType  
) const

Find all the points within a specified radius. Returns the point ids.

◆ GetModifiablePoints()

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
virtual PointsContainer * itk::PointsLocator< TPointsContainer >::GetModifiablePoints ( )
virtual

Set/Get the points from which the bounding box should be computed.

◆ GetNameOfClass()

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
const char * itk::PointsLocator< TPointsContainer >::GetNameOfClass ( ) const
overridevirtual
See also
LightObject::GetNameOfClass()

Reimplemented from itk::Object.

◆ Initialize()

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
void itk::PointsLocator< TPointsContainer >::Initialize ( )

Compute the kd-tree that will facilitate the querying the points.

◆ New()

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
static Pointer itk::PointsLocator< TPointsContainer >::New ( )
static

Method for creation through the object factory.

◆ PrintSelf()

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
void itk::PointsLocator< TPointsContainer >::PrintSelf ( std::ostream &  os,
Indent  indent 
) const
overrideprotectedvirtual

Methods invoked by Print() to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from itk::Object.

◆ SetPoints()

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
virtual void itk::PointsLocator< TPointsContainer >::SetPoints ( PointsContainer _arg)
virtual

Set/Get the points from which the bounding box should be computed.

Member Data Documentation

◆ m_KdTreeGenerator

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
TreeGeneratorPointer itk::PointsLocator< TPointsContainer >::m_KdTreeGenerator {}
private

Definition at line 119 of file itkPointsLocator.h.

◆ m_Points

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
PointsContainerPointer itk::PointsLocator< TPointsContainer >::m_Points {}
private

Definition at line 117 of file itkPointsLocator.h.

◆ m_SampleAdaptor

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
SampleAdaptorPointer itk::PointsLocator< TPointsContainer >::m_SampleAdaptor {}
private

Definition at line 118 of file itkPointsLocator.h.

◆ m_Tree

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
TreeConstPointer itk::PointsLocator< TPointsContainer >::m_Tree {}
private

Definition at line 120 of file itkPointsLocator.h.

◆ PointDimension

template<typename TPointsContainer = VectorContainer<Point<float, 3>>>
constexpr unsigned int itk::PointsLocator< TPointsContainer >::PointDimension = PointType::PointDimension
staticconstexpr

Hold on to the dimensions specified by the template parameters.

Definition at line 67 of file itkPointsLocator.h.


The documentation for this class was generated from the following file: