Class ConvertToNativeImg
Object
ConvertToNativeImg
- Author:
- Owen Feehan
-
Method Summary
Modifier and TypeMethodDescriptionstatic net.imglib2.img.NativeImg
<net.imglib2.type.numeric.integer.UnsignedByteType, net.imglib2.img.basictypeaccess.array.ByteArray> fromByte
(Voxels<UnsignedByteBuffer> voxels) Creates anNativeImg
fromVoxels
with an unsigned byte data-type.static net.imglib2.img.NativeImg
<net.imglib2.type.numeric.real.FloatType, net.imglib2.img.basictypeaccess.array.FloatArray> fromFloat
(Voxels<FloatBuffer> voxels) Creates anNativeImg
fromVoxels
with a float data-type.static net.imglib2.img.NativeImg
<net.imglib2.type.numeric.integer.UnsignedShortType, net.imglib2.img.basictypeaccess.array.ShortArray> fromShort
(Voxels<UnsignedShortBuffer> voxels) Creates anNativeImg
fromVoxels
with an unsigned short data-type.
-
Method Details
-
fromByte
public static net.imglib2.img.NativeImg<net.imglib2.type.numeric.integer.UnsignedByteType,net.imglib2.img.basictypeaccess.array.ByteArray> fromByte(Voxels<UnsignedByteBuffer> voxels) Creates anNativeImg
fromVoxels
with an unsigned byte data-type.- Parameters:
voxels
- the voxels to use in theNativeImg
.- Returns:
- the newly created
NativeImg
, either reusing the memory invoxels
or else a copy of it.
-
fromShort
public static net.imglib2.img.NativeImg<net.imglib2.type.numeric.integer.UnsignedShortType,net.imglib2.img.basictypeaccess.array.ShortArray> fromShort(Voxels<UnsignedShortBuffer> voxels) Creates anNativeImg
fromVoxels
with an unsigned short data-type.- Parameters:
voxels
- the voxels to use in theNativeImg
.- Returns:
- the newly created
NativeImg
, either reusing the memory invoxels
or else a copy of it.
-
fromFloat
public static net.imglib2.img.NativeImg<net.imglib2.type.numeric.real.FloatType,net.imglib2.img.basictypeaccess.array.FloatArray> fromFloat(Voxels<FloatBuffer> voxels) Creates anNativeImg
fromVoxels
with a float data-type.- Parameters:
voxels
- the voxels to use in theNativeImg
.- Returns:
- the newly created
NativeImg
, either reusing the memory invoxels
or else a copy of it.
-