OpenVDB
7.0.0
|
Namespaces | |
internal | |
Classes | |
struct | DirichletBoundaryOp |
Dirichlet boundary condition functor. More... | |
Typedefs | |
using | VIndex = Int32 |
using | LaplacianMatrix = math::pcg::SparseStencilMatrix< double, 7 > |
The type of a matrix used to represent a three-dimensional Laplacian operator. More... | |
using LaplacianMatrix = math::pcg::SparseStencilMatrix<double, 7> |
The type of a matrix used to represent a three-dimensional Laplacian operator.
|
inline |
Iterate over the active voxels of the input tree and for each one assign its index in the iteration sequence to the corresponding voxel of an integer-valued output tree.
|
inline |
Generate a sparse matrix of the index-space (Δx = 1) Laplacian operator using second-order finite differences.
This construction assumes homogeneous Dirichlet boundary conditions (exterior grid points are zero).
|
inline |
Generate a sparse matrix of the index-space (Δx = 1) Laplacian operator with user-specified boundary conditions using second-order finite differences.
Each thread gets its own copy of boundaryOp, which should be a functor of the form
The functor is called for each of the exterior neighbors of each boundary voxel (i, j, k), and it must specify a boundary condition for (i, j, k) by modifying one or both of two provided values: an entry in the given source vector corresponding to (i, j, k) and the weighting coefficient for (i, j, k) in the Laplacian matrix.
|
inline |
Return a tree with the same active voxel topology as the index tree but whose voxel values are taken from the the given vector.
The voxel whose value in the index tree is n gets assigned the nth element of the vector.
index | a tree with value type VIndex that maps voxels to elements of values |
values | a vector of values with which to populate the active voxels of the output tree |
background | the value for the inactive voxels of the output tree |
|
inline |
Return a vector of the active voxel values of the scalar-valued source tree.
The nth element of the vector corresponds to the voxel whose value in the index tree is n.
source | a tree with a scalar value type |
index | a tree of the same configuration as source but with value type VIndex that maps voxels to elements of the output vector |
|
inline |
Overwrite each active voxel in the given scalar tree with a sequential index, starting from zero.
|
inline |
Solve ∇2x = b for x, where b is a vector comprising the values of all of the active voxels in the input tree.
On input, the State object should specify convergence criteria (minimum error and maximum number of iterations); on output, it gives the actual termination conditions.
The solution is computed using the conjugate gradient method with (where possible) incomplete Cholesky preconditioning, falling back to Jacobi preconditioning.
|
inline |
Solve ∇2x = b for x, where b is a vector comprising the values of all of the active voxels in the input tree.
On input, the State object should specify convergence criteria (minimum error and maximum number of iterations); on output, it gives the actual termination conditions.
The solution is computed using the conjugate gradient method with (where possible) incomplete Cholesky preconditioning, falling back to Jacobi preconditioning.
|
inline |
Solve ∇2x = b for x with user-specified boundary conditions, where b is a vector comprising the values of all of the active voxels in the input tree or domain mask if provided.
On input, the State object should specify convergence criteria (minimum error and maximum number of iterations); on output, it gives the actual termination conditions.
The solution is computed using the conjugate gradient method with the specified type of preconditioner (default: incomplete Cholesky), falling back to Jacobi preconditioning if necessary.
Each thread gets its own copy of the BoundaryOp, which should be a functor of the form
The functor is called for each of the exterior neighbors of each boundary voxel (i, j, k), and it must specify a boundary condition for (i, j, k) by modifying one or both of two provided values: the entry in the source vector b corresponding to (i, j, k) and the weighting coefficient for (i, j, k) in the Laplacian operator matrix.
|
inline |
Solve ∇2x = b for x, where b is a vector comprising the values of all of the active voxels in the input tree.
On input, the State object should specify convergence criteria (minimum error and maximum number of iterations); on output, it gives the actual termination conditions.
The solution is computed using the conjugate gradient method with (where possible) incomplete Cholesky preconditioning, falling back to Jacobi preconditioning.
|
inline |
Solve ∇2x = b for x, where b is a vector comprising the values of all of the active voxels in the input tree.
On input, the State object should specify convergence criteria (minimum error and maximum number of iterations); on output, it gives the actual termination conditions.
The solution is computed using the conjugate gradient method with (where possible) incomplete Cholesky preconditioning, falling back to Jacobi preconditioning.