HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType > Struct Template Reference

Accelerated range and nearest-neighbor searches for point index grids. More...

#include <PointIndexGrid.h>

Public Types

using ConstAccessor = tree::ValueAccessor< const TreeType >
 
using LeafNodeType = typename TreeType::LeafNodeType
 
using ValueType = typename TreeType::ValueType
 

Public Member Functions

 PointIndexIterator ()
 
 PointIndexIterator (const PointIndexIterator &rhs)
 
PointIndexIteratoroperator= (const PointIndexIterator &rhs)
 
 PointIndexIterator (const Coord &ijk, ConstAccessor &acc)
 Construct an iterator over the indices of the points contained in voxel (i, j, k). More...
 
 PointIndexIterator (const CoordBBox &bbox, ConstAccessor &acc)
 Construct an iterator over the indices of the points contained in the given bounding box. More...
 
void searchAndUpdate (const Coord &ijk, ConstAccessor &acc)
 Clear the iterator and update it with the result of the given voxel query. More...
 
void searchAndUpdate (const CoordBBox &bbox, ConstAccessor &acc)
 Clear the iterator and update it with the result of the given voxel region query. More...
 
template<typename PointArray >
void searchAndUpdate (const BBoxd &bbox, ConstAccessor &acc, const PointArray &points, const math::Transform &xform)
 Clear the iterator and update it with the result of the given index-space bounding box query. More...
 
template<typename PointArray >
void searchAndUpdate (const Vec3d &center, double radius, ConstAccessor &acc, const PointArray &points, const math::Transform &xform, bool subvoxelAccuracy=true)
 Clear the iterator and update it with the result of the given index-space radial query. More...
 
template<typename PointArray >
void worldSpaceSearchAndUpdate (const BBoxd &bbox, ConstAccessor &acc, const PointArray &points, const math::Transform &xform)
 Clear the iterator and update it with the result of the given world-space bounding box query. More...
 
template<typename PointArray >
void worldSpaceSearchAndUpdate (const Vec3d &center, double radius, ConstAccessor &acc, const PointArray &points, const math::Transform &xform, bool subvoxelAccuracy=true)
 Clear the iterator and update it with the result of the given world-space radial query. More...
 
void reset ()
 Reset the iterator to point to the first item. More...
 
const ValueTypeoperator* () const
 Return a const reference to the item to which this iterator is pointing. More...
 
void increment ()
 Advance iterator to next item. More...
 
void operator++ ()
 Advance iterator to next item. More...
 
bool next ()
 Advance iterator to next item. More...
 
size_t size () const
 Return the number of point indices in the iterator range. More...
 
bool operator== (const PointIndexIterator &p) const
 Return true if both iterators point to the same element. More...
 
bool operator!= (const PointIndexIterator &p) const
 
bool test () const
 Return true if this iterator is not yet exhausted. More...
 
 operator bool () const
 Return true if this iterator is not yet exhausted. More...
 

Detailed Description

template<typename TreeType = PointIndexTree>
struct openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >

Accelerated range and nearest-neighbor searches for point index grids.

Definition at line 133 of file PointIndexGrid.h.

Member Typedef Documentation

template<typename TreeType = PointIndexTree>
using openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::ConstAccessor = tree::ValueAccessor<const TreeType>

Definition at line 135 of file PointIndexGrid.h.

template<typename TreeType = PointIndexTree>
using openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::LeafNodeType = typename TreeType::LeafNodeType

Definition at line 136 of file PointIndexGrid.h.

template<typename TreeType = PointIndexTree>
using openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::ValueType = typename TreeType::ValueType

Definition at line 137 of file PointIndexGrid.h.

Constructor & Destructor Documentation

template<typename TreeType >
openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::PointIndexIterator ( )
inline

Definition at line 922 of file PointIndexGrid.h.

template<typename TreeType >
openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::PointIndexIterator ( const PointIndexIterator< TreeType > &  rhs)
inline

Definition at line 934 of file PointIndexGrid.h.

template<typename TreeType >
openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::PointIndexIterator ( const Coord &  ijk,
ConstAccessor acc 
)
inline

Construct an iterator over the indices of the points contained in voxel (i, j, k).

Parameters
ijkthe voxel containing the points over which to iterate
accan accessor for the grid or tree that holds the point indices

Definition at line 970 of file PointIndexGrid.h.

template<typename TreeType >
openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::PointIndexIterator ( const CoordBBox &  bbox,
ConstAccessor acc 
)
inline

Construct an iterator over the indices of the points contained in the given bounding box.

Parameters
bboxthe bounding box of the voxels containing the points over which to iterate
accan accessor for the grid or tree that holds the point indices
Note
The range of the bbox is inclusive. Thus, a bounding box with min = max is not empty but rather encloses a single voxel.

Definition at line 987 of file PointIndexGrid.h.

Member Function Documentation

template<typename TreeType >
void openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::increment ( )
inline

Advance iterator to next item.

Definition at line 1022 of file PointIndexGrid.h.

template<typename TreeType >
bool openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::next ( )
inline

Advance iterator to next item.

Returns
true if this iterator is not yet exhausted.

Definition at line 1039 of file PointIndexGrid.h.

template<typename TreeType = PointIndexTree>
openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::operator bool ( ) const
inline

Return true if this iterator is not yet exhausted.

Definition at line 235 of file PointIndexGrid.h.

template<typename TreeType = PointIndexTree>
bool openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::operator!= ( const PointIndexIterator< TreeType > &  p) const
inline

Definition at line 254 of file PointIndexGrid.h.

template<typename TreeType = PointIndexTree>
const ValueType& openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::operator* ( ) const
inline

Return a const reference to the item to which this iterator is pointing.

Definition at line 230 of file PointIndexGrid.h.

template<typename TreeType = PointIndexTree>
void openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::operator++ ( )
inline

Advance iterator to next item.

Definition at line 242 of file PointIndexGrid.h.

template<typename TreeType >
PointIndexIterator< TreeType > & openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::operator= ( const PointIndexIterator< TreeType > &  rhs)
inline

Definition at line 950 of file PointIndexGrid.h.

template<typename TreeType = PointIndexTree>
bool openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::operator== ( const PointIndexIterator< TreeType > &  p) const
inline

Return true if both iterators point to the same element.

Definition at line 253 of file PointIndexGrid.h.

template<typename TreeType >
void openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::reset ( void  )
inline

Reset the iterator to point to the first item.

Definition at line 1005 of file PointIndexGrid.h.

template<typename TreeType >
void openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::searchAndUpdate ( const Coord &  ijk,
ConstAccessor acc 
)
inline

Clear the iterator and update it with the result of the given voxel query.

Parameters
ijkthe voxel containing the points over which to iterate
accan accessor for the grid or tree that holds the point indices

Definition at line 1077 of file PointIndexGrid.h.

template<typename TreeType >
void openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::searchAndUpdate ( const CoordBBox &  bbox,
ConstAccessor acc 
)
inline

Clear the iterator and update it with the result of the given voxel region query.

Parameters
bboxthe bounding box of the voxels containing the points over which to iterate
accan accessor for the grid or tree that holds the point indices
Note
The range of the bbox is inclusive. Thus, a bounding box with min = max is not empty but rather encloses a single voxel.

Definition at line 1090 of file PointIndexGrid.h.

template<typename TreeType >
template<typename PointArray >
void openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::searchAndUpdate ( const BBoxd bbox,
ConstAccessor acc,
const PointArray points,
const math::Transform xform 
)
inline

Clear the iterator and update it with the result of the given index-space bounding box query.

Parameters
bboxindex-space bounding box
accan accessor for the grid or tree that holds the point indices
pointsworld-space point array conforming to the PointArray interface
xformlinear, uniform-scale transform (i.e., cubical voxels)

Definition at line 1105 of file PointIndexGrid.h.

template<typename TreeType >
template<typename PointArray >
void openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::searchAndUpdate ( const Vec3d &  center,
double  radius,
ConstAccessor acc,
const PointArray points,
const math::Transform xform,
bool  subvoxelAccuracy = true 
)
inline

Clear the iterator and update it with the result of the given index-space radial query.

Parameters
centerindex-space center
radiusindex-space radius
accan accessor for the grid or tree that holds the point indices
pointsworld-space point array conforming to the PointArray interface
xformlinear, uniform-scale transform (i.e., cubical voxels)
subvoxelAccuracyif true, check individual points against the search region, otherwise return all points that reside in voxels that are inside or intersect the search region

Definition at line 1148 of file PointIndexGrid.h.

template<typename TreeType >
size_t openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::size ( void  ) const
inline

Return the number of point indices in the iterator range.

Definition at line 1049 of file PointIndexGrid.h.

template<typename TreeType = PointIndexTree>
bool openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::test ( ) const
inline

Return true if this iterator is not yet exhausted.

Definition at line 234 of file PointIndexGrid.h.

template<typename TreeType >
template<typename PointArray >
void openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::worldSpaceSearchAndUpdate ( const BBoxd bbox,
ConstAccessor acc,
const PointArray points,
const math::Transform xform 
)
inline

Clear the iterator and update it with the result of the given world-space bounding box query.

Parameters
bboxworld-space bounding box
accan accessor for the grid or tree that holds the point indices
pointsworld-space point array conforming to the PointArray interface
xformlinear, uniform-scale transform (i.e., cubical voxels)

Definition at line 1200 of file PointIndexGrid.h.

template<typename TreeType >
template<typename PointArray >
void openvdb::OPENVDB_VERSION_NAME::tools::PointIndexIterator< TreeType >::worldSpaceSearchAndUpdate ( const Vec3d &  center,
double  radius,
ConstAccessor acc,
const PointArray points,
const math::Transform xform,
bool  subvoxelAccuracy = true 
)
inline

Clear the iterator and update it with the result of the given world-space radial query.

Parameters
centerworld-space center
radiusworld-space radius
accan accessor for the grid or tree that holds the point indices
pointsworld-space point array conforming to the PointArray interface
xformlinear, uniform-scale transform (i.e., cubical voxels)
subvoxelAccuracyif true, check individual points against the search region, otherwise return all points that reside in voxels that are inside or intersect the search region

Definition at line 1211 of file PointIndexGrid.h.


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