public class RealViews extends Object
RealRandomAccessibles
transformed in real coordinate space by
InvertibleRealTransforms
.Constructor and Description |
---|
RealViews() |
public static <T> RealTransformRealRandomAccessible<T,InverseRealTransform> transformReal(RealRandomAccessible<T> source, InvertibleRealTransform transformFromSource)
RealRandomAccessible
as transformed by an
InvertibleRealTransform
. The InvertibleRealTransform
is
interpreted according to the natural understanding that the source is
transformed by it. E.g. a positive translation of dimension x
would shift the source to the right. Therefore, the samples need to be
generated by the inverse of the InvertibleRealTransform
. Here,
the inverse is realized by InverseRealTransform
. That way,
changing the state of the InvertibleRealTransform
will
immediately change the state of any new RealRandomAccess
generated by the view.T
- the typesource
- the RealRandomAccessible
to be transformedtransformFromSource
- the InvertibleRealTransform
transforming source
coordinates to coordinates of the returned
RealRandomAccessible
RealTransformRealRandomAccessible
representing the
transformed sourcepublic static <T> RealTransformRandomAccessible<T,InverseRealTransform> transform(RealRandomAccessible<T> source, InvertibleRealTransform transformFromSource)
RealRandomAccessible
as a RandomAccessible
transformed by an InvertibleRealTransform
. The
InvertibleRealTransform
is interpreted according to the natural
understanding that the source is transformed by it. E.g. a positive
translation of dimension x would shift the source to the right.
Therefore, the samples need to be generated by the inverse of the
InvertibleRealTransform
. Here, the inverse is realized by
InverseRealTransform
. That way, changing the state of the
InvertibleRealTransform
will immediately change the state of any
new RandomAccess
generated by the view.T
- the typesource
- the RealRandomAccessible
to be transformedtransformFromSource
- the InvertibleRealTransform
transforming source
coordinates to coordinates of the returned
RealRandomAccessible
RealTransformRandomAccessible
representing the
transformed sourcepublic static <T> AffineRealRandomAccessible<T,AffineGet> affineReal(RealRandomAccessible<T> source, AffineGet transformFromSource)
RealRandomAccessible
as transformed by an AffineGet
. The AffineGet
is interpreted according to the natural
understanding that the source is transformed by it. E.g. a positive
translation of dimension x would shift the source to the right.
Therefore, the samples need to be generated by the inverse of the
AffineGet
. Here, the AffineGet
is inverted using it's
AffineGet.inverse()
method that is expected to generate an
inverse that changes with the original transformation accordingly. That
way, changing the state of the AffineGet
will immediately change
the state of any new RealRandomAccess
generated by the view.T
- the typesource
- the RealRandomAccessible
to be transformedtransformFromSource
- the InvertibleRealTransform
transforming source
coordinates to coordinates of the returned
RealRandomAccessible
AffineRealRandomAccessible
representing the transformed
sourcepublic static <T> AffineRandomAccessible<T,AffineGet> affine(RealRandomAccessible<T> source, AffineGet transformFromSource)
RealRandomAccessible
as a RandomAccessible
transformed by an AffineGet
. The AffineGet
is interpreted
according to the natural understanding that the source is transformed by
it. E.g. a positive translation of dimension x would shift the
source to the right. Therefore, the samples need to be generated by the
inverse of the AffineGet
. Here, the AffineGet
is inverted
using it's AffineGet.inverse()
method that is expected to
generate and inverse that changes with the original transformation
accordingly. That way, changing the state of the AffineGet
will
immediately change the state of any new RandomAccess
generated
by the view.T
- the typesource
- the RealRandomAccessible
to be transformedtransformFromSource
- the InvertibleRealTransform
transforming source
coordinates to coordinates of the returned
RealRandomAccessible
AffineRandomAccessible
representing the transformed
sourcepublic static <T> RealRandomAccessible<T> addDimension(RealRandomAccessible<T> source)
RealRandomAccessible
. The resulting
RealRandomAccessible
has samples from the original dimensions
continuously stacked along the added dimensions.
The additional dimension is the last dimension. For example, an XYZ view
is created for an XY source. When accessing an XYZ sample in the view,
the final coordinate is discarded and the source XY sample is accessed.T
- the typesource
- the sourceRealRandomAccessible
public static <T> RandomAccessible<T> simplify(RealRandomAccessible<T> source)
RealTransform
s which are wrapped in the source
RealRandomAccessible
.
NB: that the resulting RandomAccessible
copies all
RealTransform
s when required. Former references on any
RealTransform
s wrapped in the RealRandomAccessible
are
invalid for the resulting RandomAccessible
.T
- the typesource
- RealRandomAccessible
to be simplifiedRandomAccessible
public static <T> RealRandomAccessible<T> simplifyReal(RealRandomAccessible<T> source)
RealTransform
s which are wrapped in the source
RealRandomAccessible
.
NB: that the resulting RealRandomAccessible
copies all
RealTransform
s when required. Former references on any
RealTransform
s wrapped in the RealRandomAccessible
are
invalid for the resulting RealRandomAccessible
.T
- the typesource
- RealRandomAccessible
to be simplifiedRealRandomAccessible
Copyright © 2015–2022 ImgLib2. All rights reserved.