Hyperbolic advection of narrow-band level sets in an external velocity field.
More...
template<typename GridT, typename FieldT = EnrightField<typename GridT::ValueType>, typename InterruptT = util::NullInterrupter>
class openvdb::v3_2_0::tools::LevelSetAdvection< GridT, FieldT, InterruptT >
Hyperbolic advection of narrow-band level sets in an external velocity field.
The FieldType
template argument below refers to any functor with the following interface (see tools/VelocityFields.h for examples):
class VelocityField {
...
public:
openvdb::VectorType operator() (
const openvdb::Coord& xyz,
ValueType time)
const;
...
};
- Note
- The functor method returns the velocity field at coordinate position xyz of the advection grid, and for the specified time. Note that since the velocity is returned in the local coordinate space of the grid that is being advected, the functor typically depends on the transformation of that grid. This design is chosen for performance reasons. Finally we will assume that the functor method is NOT threadsafe (typically uses a ValueAccessor) and that its lightweight enough that we can copy it per thread.
The InterruptType
template argument below refers to any class with the following interface:
class Interrupter {
...
public:
void start(const char* name = NULL)
void end()
};
- Note
- If no template argument is provided for this InterruptType the util::NullInterrupter is used which implies that all interrupter calls are no-ops (i.e. incurs no computational overhead).