iLab Neuromorphic Robotics Toolkit  0.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
nrt::PointCloud2::ConstIterator< FirstT, OtherT...> Class Template Reference

#include <nrt/PointCloud2/details/PointCloud2Impl.H>

template<class FirstT, class... OtherT>
class nrt::PointCloud2::ConstIterator< FirstT, OtherT...>

Template specialization for ConstIterator with variadic template parameters.

Specialization for having specific fields

Definition at line 1458 of file PointCloud2Impl.H.

Inherits iterator_facade< ConstIterator< FirstT, OtherT...>, PointCloud2ConstDataRef< StripSparse< FirstT >::type, StripSparse< OtherT >::type...>, boost::random_access_traversal_tag, PointCloud2ConstDataRef< StripSparse< FirstT >::type, StripSparse< OtherT >::type...> >.

Public Types

typedef boost::iterator_facade
< ConstIterator< FirstT,
OtherT...>
, PointCloud2ConstDataRef
< typename StripSparse< FirstT >
::type, typename StripSparse
< OtherT >::type...>
, boost::random_access_traversal_tag,
PointCloud2ConstDataRef
< typename StripSparse< FirstT >
::type, typename StripSparse
< OtherT >::type...>
>::difference_type 
difference_type
 Used internally by boost.
 

Public Member Functions

 ConstIterator (PointCloud2 const *const cloud, size_t index)
 Creates a dense iterator located at a certain index in the cloud. More...
 
 ConstIterator (PointCloud2 const *const cloud, size_t index, bool sparse)
 Creates a sparse iterator located at a certain index in the cloud. More...
 
 ConstIterator (PointCloud2 const *const cloud, size_t index, Indices const indices)
 Creates an iterator over a specific subset of dense points. More...
 
 ConstIterator (PointCloud2 const *const cloud, size_t index, Indices const indices, bool sparse)
 Creates an iterator over a specific subset of sparse points. More...
 
 ConstIterator (ConstIterator const &other)=default
 Copy construction.
 
bool sparse () const
 Get whether we contain sparse fields.
 
size_t index () const
 Get the current index in the point cloud of the iterator. More...
 

Friends

class boost::iterator_core_access
 

Constructor & Destructor Documentation

template<class FirstT , class... OtherT>
nrt::PointCloud2::ConstIterator< FirstT, OtherT...>::ConstIterator ( PointCloud2 const *const  cloud,
size_t  index 
)

Creates a dense iterator located at a certain index in the cloud.

Parameters
cloudThe point cloud
indexThe starting index
template<class FirstT , class... OtherT>
nrt::PointCloud2::ConstIterator< FirstT, OtherT...>::ConstIterator ( PointCloud2 const *const  cloud,
size_t  index,
bool  sparse 
)

Creates a sparse iterator located at a certain index in the cloud.

Parameters
cloudThe point cloud
indexThe starting index
sparsevalue ignored
template<class FirstT , class... OtherT>
nrt::PointCloud2::ConstIterator< FirstT, OtherT...>::ConstIterator ( PointCloud2 const *const  cloud,
size_t  index,
Indices const  indices 
)

Creates an iterator over a specific subset of dense points.

Parameters
cloudThe point cloud
indexThe starting index in the set of indices
indicesThe indices that define a subset
template<class FirstT , class... OtherT>
nrt::PointCloud2::ConstIterator< FirstT, OtherT...>::ConstIterator ( PointCloud2 const *const  cloud,
size_t  index,
Indices const  indices,
bool  sparse 
)

Creates an iterator over a specific subset of sparse points.

Parameters
cloudThe point cloud
indexThe starting index in the set of indices
indicesThe indices that define a subset
sparsevalue ignored

Member Function Documentation

template<class FirstT , class... OtherT>
size_t nrt::PointCloud2::ConstIterator< FirstT, OtherT...>::index ( ) const

Get the current index in the point cloud of the iterator.

The value returned is not guaranteed to be valid if the iterator is not within the bounds of the cloud


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