OpenVDB  9.0.1
Classes | Namespaces | Typedefs
IndexFilter.h File Reference

Index filters primarily designed to be used with a FilterIndexIter. More...

#include <openvdb/version.h>
#include <openvdb/Types.h>
#include <openvdb/math/Transform.h>
#include <openvdb/tools/Interpolation.h>
#include "IndexIterator.h"
#include "AttributeArray.h"
#include "AttributeGroup.h"
#include "AttributeSet.h"
#include <random>
#include <numeric>
#include <unordered_map>

Go to the source code of this file.

Classes

class  ValueMaskFilter< On >
 Index filtering on active / inactive state of host voxel. More...
 
class  MultiGroupFilter
 
class  RandomLeafFilter< PointDataTreeT, RandGenT >
 
class  AttributeHashFilter< RandGenT, IntType >
 
class  LevelSetFilter< LevelSetGridT >
 
class  BBoxFilter
 
class  BinaryFilter< T1, T2, And >
 
struct  FilterTraits< T >
 
struct  FilterTraits< BBoxFilter >
 
struct  FilterTraits< LevelSetFilter< T > >
 
struct  FilterTraits< BinaryFilter< T0, T1, And > >
 

Namespaces

 openvdb
 
 openvdb::v9_0
 
 openvdb::v9_0::points
 

Typedefs

using ActiveFilter = ValueMaskFilter< true >
 
using InactiveFilter = ValueMaskFilter< false >
 

Detailed Description

Index filters primarily designed to be used with a FilterIndexIter.

Author
Dan Bailey

Filters must adhere to the interface described in the example below:

struct MyFilter
{
// Return true when the filter has been initialized for first use
bool initialized() { return true; }
// Return index::ALL if all points are valid, index::NONE if no points are valid
// and index::PARTIAL if some points are valid
index::State state() { return index::PARTIAL; }
// Return index::ALL if all points in this leaf are valid, index::NONE if no points
// in this leaf are valid and index::PARTIAL if some points in this leaf are valid
template <typename LeafT>
index::State state(const LeafT&) { return index::PARTIAL; }
// Resets the filter to refer to the specified leaf, all subsequent valid() calls
// will be relative to this leaf until reset() is called with a different leaf.
// Although a required method, many filters will provide an empty implementation if
// there is no leaf-specific logic needed.
template <typename LeafT> void reset(const LeafT&) { }
// Returns true if the filter is valid for the supplied iterator
template <typename IterT> bool valid(const IterT&) { return true; }
};