HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT > Class Template Reference

Apply an operator to an input grid to produce an output grid with the same active voxel topology but a potentially different value type. More...

#include <GridOperators.h>

Public Types

typedef OutGridT::TreeType OutTreeT
 
typedef OutTreeT::LeafNodeType OutLeafT
 
typedef tree::LeafManager
< OutTreeT
LeafManagerT
 

Public Member Functions

 GridOperator (const InGridT &grid, const MaskGridType *mask, const MapT &map, InterruptT *interrupt=nullptr, bool densify=true)
 
 GridOperator (const GridOperator &)=default
 
GridOperatoroperator= (const GridOperator &)=default
 
virtual ~GridOperator ()=default
 
OutGridT::Ptr process (bool threaded=true)
 
void operator() (const typename LeafManagerT::LeafRange &range) const
 Iterate sequentially over LeafNodes and voxels in the output grid and apply the operator using a value accessor for the input grid. More...
 

Protected Types

typedef InGridT::ConstAccessor AccessorT
 

Protected Attributes

AccessorT mAcc
 
const MapT & mMap
 
InterruptT * mInterrupt
 
const MaskGridType * mMask
 
const bool mDensify
 

Detailed Description

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
class openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >

Apply an operator to an input grid to produce an output grid with the same active voxel topology but a potentially different value type.

To facilitate inlining, this class is also templated on a Map type.

Note
This is a helper class and should never be used directly.

Definition at line 302 of file GridOperators.h.

Member Typedef Documentation

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
typedef InGridT::ConstAccessor openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::AccessorT
protected

Definition at line 401 of file GridOperators.h.

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
typedef tree::LeafManager<OutTreeT> openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::LeafManagerT

Definition at line 307 of file GridOperators.h.

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
typedef OutTreeT::LeafNodeType openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::OutLeafT

Definition at line 306 of file GridOperators.h.

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
typedef OutGridT::TreeType openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::OutTreeT

Definition at line 305 of file GridOperators.h.

Constructor & Destructor Documentation

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::GridOperator ( const InGridT &  grid,
const MaskGridType *  mask,
const MapT &  map,
InterruptT *  interrupt = nullptr,
bool  densify = true 
)
inline

Definition at line 309 of file GridOperators.h.

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::GridOperator ( const GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT > &  )
default
template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
virtual openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::~GridOperator ( )
virtualdefault

Member Function Documentation

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
void openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::operator() ( const typename LeafManagerT::LeafRange range) const
inline

Iterate sequentially over LeafNodes and voxels in the output grid and apply the operator using a value accessor for the input grid.

Note
Never call this public method directly - it is called by TBB threads only!

Definition at line 387 of file GridOperators.h.

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
GridOperator& openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::operator= ( const GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT > &  )
default
template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
OutGridT::Ptr openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::process ( bool  threaded = true)
inline
Todo:
Can tiles be handled correctly without densification, or by densifying only to the width of the operator stencil?

Definition at line 322 of file GridOperators.h.

Member Data Documentation

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
AccessorT openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::mAcc
mutableprotected

Definition at line 402 of file GridOperators.h.

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
const bool openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::mDensify
protected

Definition at line 406 of file GridOperators.h.

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
InterruptT* openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::mInterrupt
protected

Definition at line 404 of file GridOperators.h.

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
const MapT& openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::mMap
protected

Definition at line 403 of file GridOperators.h.

template<typename InGridT, typename MaskGridType, typename OutGridT, typename MapT, typename OperatorT, typename InterruptT = util::NullInterrupter>
const MaskGridType* openvdb::OPENVDB_VERSION_NAME::tools::gridop::GridOperator< InGridT, MaskGridType, OutGridT, MapT, OperatorT, InterruptT >::mMask
protected

Definition at line 405 of file GridOperators.h.


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