public abstract class VoxelsResizer extends Object
Constructor and Description |
---|
VoxelsResizer() |
Modifier and Type | Method and Description |
---|---|
abstract boolean |
canValueRangeChange()
Returns true if it's possible for values to be created after interpolation that aren't found
in the input-image.
|
void |
resize(VoxelsUntyped source,
VoxelsUntyped destination)
Copies voxels slice-by-slice from
source to destination performing necessary
interpolation. |
protected abstract VoxelBuffer<UnsignedByteBuffer> |
resizeByte(VoxelBuffer<UnsignedByteBuffer> voxelsSource,
VoxelBuffer<UnsignedByteBuffer> voxelsDestination,
Extent extentSource,
Extent extentDestination)
Interpolates from
voxelsSource to voxelsDestination for unsigned 8-bit
buffers. |
protected abstract VoxelBuffer<FloatBuffer> |
resizeFloat(VoxelBuffer<FloatBuffer> voxelsSource,
VoxelBuffer<FloatBuffer> voxelsDestination,
Extent extentSource,
Extent extentDestination)
Interpolates from
voxelsSource to voxelsDestination for float buffers. |
protected abstract VoxelBuffer<UnsignedShortBuffer> |
resizeShort(VoxelBuffer<UnsignedShortBuffer> voxelsSource,
VoxelBuffer<UnsignedShortBuffer> voxelsDestination,
Extent extentSource,
Extent extentDestination)
Interpolates from
voxelsSource to voxelsDestination for unsigned 16-bit
buffers. |
public void resize(VoxelsUntyped source, VoxelsUntyped destination)
source
to destination
performing necessary
interpolation.
Note that interpolation only occurs in the XY plane, and the number of Z-slices should be
identical for both source
and destination
.
source
- the voxels to copy from.destination
- the voxels to copy interpolated-values into, which may differ in size in
the XY dimensions.public abstract boolean canValueRangeChange()
protected abstract VoxelBuffer<UnsignedByteBuffer> resizeByte(VoxelBuffer<UnsignedByteBuffer> voxelsSource, VoxelBuffer<UnsignedByteBuffer> voxelsDestination, Extent extentSource, Extent extentDestination)
voxelsSource
to voxelsDestination
for unsigned 8-bit
buffers.
Both buffers must be 2-dimensional, not 3-dimensional.
voxelsSource
- voxels to interpolate from.voxelsDestination
- voxels to write the interpolated values into.extentSource
- extent corresponding to voxelsSource
.extentDestination
- extent corresponding to extentDestination
.protected abstract VoxelBuffer<UnsignedShortBuffer> resizeShort(VoxelBuffer<UnsignedShortBuffer> voxelsSource, VoxelBuffer<UnsignedShortBuffer> voxelsDestination, Extent extentSource, Extent extentDestination)
voxelsSource
to voxelsDestination
for unsigned 16-bit
buffers.
Both buffers must be 2-dimensional, not 3-dimensional.
voxelsSource
- voxels to interpolate from.voxelsDestination
- voxels to write the interpolated values into.extentSource
- extent corresponding to voxelsSource
.extentDestination
- extent corresponding to extentDestination
.protected abstract VoxelBuffer<FloatBuffer> resizeFloat(VoxelBuffer<FloatBuffer> voxelsSource, VoxelBuffer<FloatBuffer> voxelsDestination, Extent extentSource, Extent extentDestination)
voxelsSource
to voxelsDestination
for float buffers.
Both buffers must be 2-dimensional, not 3-dimensional.
voxelsSource
- voxels to interpolate from.voxelsDestination
- voxels to write the interpolated values into.extentSource
- extent corresponding to voxelsSource
.extentDestination
- extent corresponding to extentDestination
.Copyright © 2010–2023 Owen Feehan, ETH Zurich, University of Zurich, Hoffmann-La Roche. All rights reserved.