public class IterateVoxelsObjectMaskOptional extends Object
ObjectMask
.
If the ObjectMask
is not defined, then all voxels are iterated over.
The utilities operate on one or more Voxels
. A processor is called on each selected
voxel.
Modifier and Type | Method and Description |
---|---|
static <T> void |
withBuffer(Optional<ObjectMask> objectMask,
Voxels<T> voxels,
ProcessBufferUnary<T> process)
Iterate over each voxel (or optionally only on object-mask) with one associated
buffer.
|
static void |
withPoint(Optional<ObjectMask> objectMask,
Extent extent,
ProcessPoint process)
Iterate over all points that are located on a object-mask or else all points in an extent.
|
static void |
withSlidingBuffer(Optional<ObjectMask> objectMask,
SlidingBuffer<?> buffer,
ProcessPoint process)
Iterate over each voxel in a sliding-buffer, optionally restricting it to be only voxels in a
certain object
|
static <S,T> void |
withTwoBuffers(Optional<ObjectMask> objectMask,
Voxels<S> voxels1,
Voxels<T> voxels2,
ProcessBufferBinary<S,T> process)
Iterate over each voxel (or optionally only on object-mask) with two associated
buffers.
|
public static void withPoint(Optional<ObjectMask> objectMask, Extent extent, ProcessPoint process)
objectMask
- an optional object-mask that is used as a condition on what voxels to
iterate. If not defined, all voxels are iterated over.extent
- if object-mask isn't defined, then all the voxels in this Extent
are
iterated over insteadprocess
- process is called for each voxel (on the entire Extent
or on the
object-mask depending) using global coordinates.public static <T> void withBuffer(Optional<ObjectMask> objectMask, Voxels<T> voxels, ProcessBufferUnary<T> process)
T
- buffer-type for voxelsobjectMask
- an optional object-mask that is used as a condition on what voxels to
iterate. If not defined, all voxels are iterated over.voxels
- voxels where buffers extracted from be processed, and which define the global
coordinate spaceprocess
- is called for each voxel within the bounding-box using global
coordinates.public static <S,T> void withTwoBuffers(Optional<ObjectMask> objectMask, Voxels<S> voxels1, Voxels<T> voxels2, ProcessBufferBinary<S,T> process)
T
- buffer-type for voxelsobjectMask
- an optional object-mask that is used as a condition on what voxels to
iterate. If not defined, all voxels are iterated over.voxels1
- voxels that provide the first voxel-buffervoxels2
- voxels that provide the second bufferprocess
- is called for each voxel within the bounding-box using global
coordinates.public static void withSlidingBuffer(Optional<ObjectMask> objectMask, SlidingBuffer<?> buffer, ProcessPoint process)
buffer
- a sliding-buffer whose voxels are iterated over, partially (if an objectmask is
defined) or as a whole (if no onject-mask is defined)objectMask
- an optional object-mask that is used as a condition on what voxels to
iterateprocess
- process is called for each voxel (on the entire SlidingBuffer
or on
the object-mask depending) using global coordinates.Copyright © 2010–2023 Owen Feehan, ETH Zurich, University of Zurich, Hoffmann-La Roche. All rights reserved.