OpenVDB  1.1.0
Public Types | Public Member Functions | List of all members
GridSampler< TreeOrAccessorType, SamplerType > Class Template Reference

Base class that provides the interface for continuous sampling of values in a grid. More...

#include <Interpolation.h>

Public Types

typedef boost::shared_ptr
< GridSampler
Ptr
typedef
TreeOrAccessorType::ValueType 
ValueType

Public Member Functions

 GridSampler (const TreeOrAccessorType &tree, const math::Transform &transform=math::Transform())
 ~GridSampler ()
template<typename RealType >
ValueType sampleVoxel (const RealType &x, const RealType &y, const RealType &z) const
 Sample a point in index space in the grid.
ValueType isSample (const Vec3d &ispoint) const
 Sample in index space.
ValueType wsSample (const Vec3d &wspoint) const
 Sample in world space.

Detailed Description

template<typename TreeOrAccessorType, typename SamplerType>
class openvdb::v1_1_0::tools::GridSampler< TreeOrAccessorType, SamplerType >

Base class that provides the interface for continuous sampling of values in a grid.

Since grids support only discrete voxel sampling, GridSampler must be used to sample arbitrary continuous points in (world or index) space.

Member Typedef Documentation

typedef boost::shared_ptr<GridSampler> Ptr
typedef TreeOrAccessorType::ValueType ValueType

Constructor & Destructor Documentation

GridSampler ( const TreeOrAccessorType &  tree,
const math::Transform transform = math::Transform() 
)
inlineexplicit
Parameters
treea tree to be sampled, or a ValueAccessor for the tree
transformis used when sampling world space locations. (by default an identity transform is used)
~GridSampler ( )
inline

Member Function Documentation

ValueType isSample ( const Vec3d ispoint) const
inline

Sample in index space.

Parameters
ispointthe location in index space
ValueType sampleVoxel ( const RealType &  x,
const RealType &  y,
const RealType &  z 
) const
inline

Sample a point in index space in the grid.

Parameters
xx-coordinate of point in index-coordinates of grid
yy-coordinate of point in index-coordinates of grid
zz-coordinate of point in index-coordinates of grid
ValueType wsSample ( const Vec3d wspoint) const
inline

Sample in world space.

Parameters
wspointthe location in world space

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