T
- public class FloorInterpolator<T> extends Floor<RandomAccess<T>> implements RealRandomAccess<T>
RealRandomAccess
to a RandomAccess
by nearest floor
interpolation (i.e., the value is sampled at floor(x)).
In ImgLib2, the coordinate of a sample corresponds to the 'center' point
of the sample, i.e. the location at which the sample was acquired. This
scheme is intuitive in both rasters and irregularly samples data but can
trigger confusion when displaying images on a screen with a pixel raster
which, in this scheme, spans the range [-0.5,width-0.5]. In the
screen-friendly alternative scheme, where sample coordinates reference the
top left corner of the pixel rectangle representing a sample the range
covered by an image is [0,width], however, coordinate transfer
functions other than translation and homogeneous scaling generate different
results than in the center-scheme. Rendering an image using
FloorInterpolator
means using the top-left-scheme, rendering it
using NearestNeighborInterpolator
, NLinearInterpolator
, or
LanczosInterpolator
means using the center-scheme.
discrete, position, target
n
Modifier | Constructor and Description |
---|---|
protected |
FloorInterpolator(FloorInterpolator<T> floorInterpolator) |
protected |
FloorInterpolator(RandomAccessible<T> randomAccessible) |
Modifier and Type | Method and Description |
---|---|
FloorInterpolator<T> |
copy() |
FloorInterpolator<T> |
copyRealRandomAccess() |
T |
get()
Access the actual T instance providing access to a pixel,
sub-pixel or integral region value the
Sampler points at. |
floor, floor, floor, floor, floor, move, move, move, move, move, setPosition, setPosition, setPosition, setPosition, setPosition
bck, fwd, getDoublePosition, getFloatPosition, localize, localize, move, move, move, move, move, setPosition, setPosition, setPosition, setPosition, setPosition, toString
numDimensions
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
setPositionAndGet, setPositionAndGet, setPositionAndGet
getDoublePosition, getFloatPosition, localize, localize, localize, positionAsDoubleArray, positionAsRealPoint
move, move, move, move, move, setPosition, setPosition, setPosition, setPosition, setPosition
bck, fwd, move, move, move, move, move, setPosition, setPosition, setPosition, setPosition, setPosition
numDimensions
protected FloorInterpolator(FloorInterpolator<T> floorInterpolator)
protected FloorInterpolator(RandomAccessible<T> randomAccessible)
public T get()
Sampler
Sampler
points at.public FloorInterpolator<T> copy()
copy
in interface Sampler<T>
Sampler
in the same state accessing the same
values.
It does NOT copy T, just the state of the Sampler
.
Otherwise use T.copy() if available.
Sampler.copy().get() == Sampler.get(), i.e. both hold the same
value, not necessarily the same instance (this is the case for an
ArrayCursor
for example)public FloorInterpolator<T> copyRealRandomAccess()
copyRealRandomAccess
in interface RealRandomAccess<T>
Copyright © 2015–2022 ImgLib2. All rights reserved.