MeshLib Documentation
Loading...
Searching...
No Matches
MR::RangeProcessorSingle< TreeT, Proc > Class Template Reference

Class to use in tbb::parallel_reduce for tree operations that do not require an output tree. More...

#include <MROpenVDBHelper.h>

Public Types

using InterruptFunc = std::function<bool( void )>
 
using ProgressHolder = std::shared_ptr<RangeProgress>
 
using ValueT = typename TreeT::ValueType
 
using LeafIterT = typename TreeT::LeafCIter
 
using TileIterT = typename TreeT::ValueAllCIter
 
using LeafRange = typename openvdb::tree::IteratorRange<LeafIterT>
 
using TileRange = typename openvdb::tree::IteratorRange<TileIterT>
 
using TreeAccessor = typename openvdb::tree::ValueAccessor<const TreeT>
 

Public Member Functions

 RangeProcessorSingle (const openvdb::math::CoordBBox &b, const TreeT &inT, const Proc &proc)
 
 RangeProcessorSingle (RangeProcessorSingle &other, tbb::split)
 Splitting constructor: don't copy the original processor's output tree.
 
void setInterrupt (const InterruptFunc &f)
 
void setProgressHolder (ProgressHolder progressHolder)
 
void operator() (const LeafRange &rCRef)
 Transform each leaf node in the given range.
 
void operator() (const TileRange &rCRef)
 Transform each non-background tile in the given range.
 
void join (RangeProcessorSingle &other)
 Merge another processor's output tree into this processor's tree.
 

Public Attributes

Proc mProc
 

Detailed Description

template<typename TreeT, typename Proc>
class MR::RangeProcessorSingle< TreeT, Proc >

Class to use in tbb::parallel_reduce for tree operations that do not require an output tree.

Template Parameters
TreeTtree type
Procfunctor for operations on a tree

Member Typedef Documentation

◆ InterruptFunc

template<typename TreeT , typename Proc >
using MR::RangeProcessorSingle< TreeT, Proc >::InterruptFunc = std::function<bool( void )>

◆ LeafIterT

template<typename TreeT , typename Proc >
using MR::RangeProcessorSingle< TreeT, Proc >::LeafIterT = typename TreeT::LeafCIter

◆ LeafRange

template<typename TreeT , typename Proc >
using MR::RangeProcessorSingle< TreeT, Proc >::LeafRange = typename openvdb::tree::IteratorRange<LeafIterT>

◆ ProgressHolder

template<typename TreeT , typename Proc >
using MR::RangeProcessorSingle< TreeT, Proc >::ProgressHolder = std::shared_ptr<RangeProgress>

◆ TileIterT

template<typename TreeT , typename Proc >
using MR::RangeProcessorSingle< TreeT, Proc >::TileIterT = typename TreeT::ValueAllCIter

◆ TileRange

template<typename TreeT , typename Proc >
using MR::RangeProcessorSingle< TreeT, Proc >::TileRange = typename openvdb::tree::IteratorRange<TileIterT>

◆ TreeAccessor

template<typename TreeT , typename Proc >
using MR::RangeProcessorSingle< TreeT, Proc >::TreeAccessor = typename openvdb::tree::ValueAccessor<const TreeT>

◆ ValueT

template<typename TreeT , typename Proc >
using MR::RangeProcessorSingle< TreeT, Proc >::ValueT = typename TreeT::ValueType

Constructor & Destructor Documentation

◆ RangeProcessorSingle() [1/2]

template<typename TreeT , typename Proc >
MR::RangeProcessorSingle< TreeT, Proc >::RangeProcessorSingle ( const openvdb::math::CoordBBox & b,
const TreeT & inT,
const Proc & proc )
inline

◆ RangeProcessorSingle() [2/2]

template<typename TreeT , typename Proc >
MR::RangeProcessorSingle< TreeT, Proc >::RangeProcessorSingle ( RangeProcessorSingle< TreeT, Proc > & other,
tbb::split  )
inline

Splitting constructor: don't copy the original processor's output tree.

Member Function Documentation

◆ join()

template<typename TreeT , typename Proc >
void MR::RangeProcessorSingle< TreeT, Proc >::join ( RangeProcessorSingle< TreeT, Proc > & other)
inline

Merge another processor's output tree into this processor's tree.

◆ operator()() [1/2]

template<typename TreeT , typename Proc >
void MR::RangeProcessorSingle< TreeT, Proc >::operator() ( const LeafRange & rCRef)
inline

Transform each leaf node in the given range.

◆ operator()() [2/2]

template<typename TreeT , typename Proc >
void MR::RangeProcessorSingle< TreeT, Proc >::operator() ( const TileRange & rCRef)
inline

Transform each non-background tile in the given range.

◆ setInterrupt()

template<typename TreeT , typename Proc >
void MR::RangeProcessorSingle< TreeT, Proc >::setInterrupt ( const InterruptFunc & f)
inline

◆ setProgressHolder()

template<typename TreeT , typename Proc >
void MR::RangeProcessorSingle< TreeT, Proc >::setProgressHolder ( ProgressHolder progressHolder)
inline

Member Data Documentation

◆ mProc

template<typename TreeT , typename Proc >
Proc MR::RangeProcessorSingle< TreeT, Proc >::mProc

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