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

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

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

Template specialization for Iteartor with variadic templates.

Specialization for having specific fields

Definition at line 1100 of file PointCloud2Impl.H.

Inherits iterator_facade< Iterator< FirstT, OtherT...>, PointCloud2DataRef< StripSparse< FirstT >::type, StripSparse< OtherT >::type...>, boost::random_access_traversal_tag, PointCloud2DataRef< StripSparse< FirstT >::type, StripSparse< OtherT >::type...> >.

Public Types

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

Public Member Functions

 Iterator (PointCloud2 *const cloud, size_t index)
 Creates a dense iterator located at a certain index in the cloud. More...
 
 Iterator (PointCloud2 *const cloud, size_t index, bool sparse)
 Creates a sparse iterator located at a certain index in the cloud. More...
 
 Iterator (PointCloud2 *const cloud, size_t index, Indices const indices)
 Creates an iterator over a specific subset of dense points. More...
 
 Iterator (PointCloud2 *const cloud, size_t index, Indices const indices, bool sparse)
 Creates an iterator over a specific subset of sparse points. More...
 
 Iterator (Iterator 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::Iterator< FirstT, OtherT...>::Iterator ( PointCloud2 *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::Iterator< FirstT, OtherT...>::Iterator ( PointCloud2 *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::Iterator< FirstT, OtherT...>::Iterator ( PointCloud2 *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::Iterator< FirstT, OtherT...>::Iterator ( PointCloud2 *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::Iterator< 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: