10 #ifndef OPENVDB_POINTS_POINT_SAMPLE_HAS_BEEN_INCLUDED 11 #define OPENVDB_POINTS_POINT_SAMPLE_HAS_BEEN_INCLUDED 14 #include <openvdb/thread/Threading.h> 22 #include <type_traits> 38 template<
typename PointDataGridT,
typename SourceGridT,
39 typename FilterT = NullFilter,
typename InterrupterT = util::NullInterrupter>
41 const SourceGridT& sourceGrid,
42 const Name& targetAttribute =
"",
43 const FilterT& filter = NullFilter(),
44 InterrupterT*
const interrupter =
nullptr);
55 template<
typename PointDataGridT,
typename SourceGridT,
56 typename FilterT = NullFilter,
typename InterrupterT = util::NullInterrupter>
57 inline void boxSample( PointDataGridT& points,
58 const SourceGridT& sourceGrid,
59 const Name& targetAttribute =
"",
60 const FilterT& filter = NullFilter(),
61 InterrupterT*
const interrupter =
nullptr);
72 template<
typename PointDataGridT,
typename SourceGridT,
73 typename FilterT = NullFilter,
typename InterrupterT = util::NullInterrupter>
75 const SourceGridT& sourceGrid,
76 const Name& targetAttribute =
"",
77 const FilterT& filter = NullFilter(),
78 InterrupterT*
const interrupter =
nullptr);
87 template<
typename ValueT,
typename SamplerT,
typename AccessorT>
88 inline ValueT sample(
const AccessorT& accessor,
const Vec3d& position)
const;
108 template<
typename PointDataGridT,
typename SourceGridT,
typename TargetValueT =
DummySampleType,
112 PointDataGridT& points,
113 const SourceGridT& sourceGrid,
114 const Name& targetAttribute,
117 InterrupterT*
const interrupter =
nullptr,
126 #endif // OPENVDB_POINTS_POINT_SAMPLE_HAS_BEEN_INCLUDED void sampleGrid(size_t order, PointDataGridT &points, const SourceGridT &sourceGrid, const Name &targetAttribute, const FilterT &filter=NullFilter(), const SamplerT &sampler=SampleWithRounding(), InterrupterT *const interrupter=nullptr, const bool threaded=true)
Performs sampling and conversion from a VDB grid onto a VDB Points attribute.
Definition: PointSampleImpl.h:319
void quadraticSample(PointDataGridT &points, const SourceGridT &sourceGrid, const Name &targetAttribute="", const FilterT &filter=NullFilter(), InterrupterT *const interrupter=nullptr)
Performs tri-quadratic sampling from a VDB grid onto a VDB Points attribute.
Definition: PointSampleImpl.h:439
void boxSample(PointDataGridT &points, const SourceGridT &sourceGrid, const Name &targetAttribute="", const FilterT &filter=NullFilter(), InterrupterT *const interrupter=nullptr)
Performs tri-linear sampling from a VDB grid onto a VDB Points attribute.
Definition: PointSampleImpl.h:428
Base class for interrupters.
Definition: NullInterrupter.h:25
Point attribute manipulation in a VDB Point Grid.
Definition: Exceptions.h:13
Definition: PointSample.h:85
Definition: PointSample.h:93
Attribute-owned data structure for points. Point attributes are stored in leaf nodes and ordered by v...
std::string Name
Definition: Name.h:19
#define OPENVDB_VERSION_NAME
The version namespace name for this library version.
Definition: version.h.in:121
void pointSample(PointDataGridT &points, const SourceGridT &sourceGrid, const Name &targetAttribute="", const FilterT &filter=NullFilter(), InterrupterT *const interrupter=nullptr)
Performs closest point sampling from a VDB grid onto a VDB Points attribute.
Definition: PointSampleImpl.h:417
#define OPENVDB_USE_VERSION_NAMESPACE
Definition: version.h.in:218
A no-op filter that can be used when iterating over all indices.
Definition: IndexIterator.h:51