OpenVDB 12.0.0
 
Loading...
Searching...
No Matches
PointsToMask< GridT, InterrupterT >::ReducePool Struct Reference

#include <openvdb/tools/PointsToMask.h>

Public Types

using VecT = std::vector<GridT*>
 
using IterT = typename VecT::iterator
 
using RangeT = tbb::blocked_range<IterT>
 
using ValueT
 

Public Member Functions

 ReducePool (PoolType &pool, GridT *grid, size_t grainSize=1)
 
 ReducePool (const ReducePool &, tbb::split)
 
 ~ReducePool ()
 
void operator() (const RangeT &r)
 
void join (ReducePool &other)
 
 PointsToMask (GridT &grid, InterrupterT *interrupter=nullptr)
 Constructor from a grid and optional interrupter.
 
void addPoints (const PointListT &points, size_t grainSize=1024)
 Activates the state of any voxel in the input grid that contains a point.
 

Public Attributes

const bool mOwnsGrid
 
GridT * mGrid
 

Member Typedef Documentation

◆ IterT

template<typename GridT, typename InterrupterT>
using IterT = typename VecT::iterator

◆ RangeT

template<typename GridT, typename InterrupterT>
using RangeT = tbb::blocked_range<IterT>

◆ ValueT

using ValueT

◆ VecT

template<typename GridT, typename InterrupterT>
using VecT = std::vector<GridT*>

Constructor & Destructor Documentation

◆ ReducePool() [1/2]

template<typename GridT, typename InterrupterT>
ReducePool ( PoolType & pool,
GridT * grid,
size_t grainSize = 1 )
inline

◆ ReducePool() [2/2]

template<typename GridT, typename InterrupterT>
ReducePool ( const ReducePool & ,
tbb::split  )
inline

◆ ~ReducePool()

template<typename GridT, typename InterrupterT>
~ReducePool ( )
inline

Member Function Documentation

◆ addPoints()

void addPoints ( const PointListT & points,
size_t grainSize = 1024 )
inline

Activates the state of any voxel in the input grid that contains a point.

Parameters
pointsList of points that active the voxels in the input grid.
grainSizeSet the grain-size used for multi-threading. A value of 0 disables multi-threading!

◆ join()

template<typename GridT, typename InterrupterT>
void join ( ReducePool & other)
inline

◆ operator()()

template<typename GridT, typename InterrupterT>
void operator() ( const RangeT & r)
inline

◆ PointsToMask()

PointsToMask ( GridT & grid,
InterrupterT * interrupter = nullptr )
inlineexplicit

Constructor from a grid and optional interrupter.

Parameters
gridGrid whose voxels will have their state activated by points.
interrupterOptional interrupter to prematurely terminate execution.

Member Data Documentation

◆ mGrid

template<typename GridT, typename InterrupterT>
GridT* mGrid

◆ mOwnsGrid

template<typename GridT, typename InterrupterT>
const bool mOwnsGrid