Package net.imglib2.img.cell
Class Cell<A>
java.lang.Object
net.imglib2.img.cell.Cell<A>
- All Implemented Interfaces:
Serializable
A cell of an
AbstractCellImg.- Author:
- Tobias Pietzsch
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final int[]protected final long[]protected final long[]protected final intprotected final int[] -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintdimension(int d) Get the number of pixels in a given dimension d.voiddimensions(int[] dim) Write the number of pixels in each dimension into long[].getData()Get the basic type array that stores this cells pixels.intglobalPositionToIndex(long[] position) Compute the index in the underlying flat array of this cell which corresponds to the specified globalposition.longindexToGlobalPosition(int index, int d) voidindexToGlobalPosition(int index, long[] position) longmin(int d) voidmin(long[] minimum) Write the minimum of each dimension into long[].longsize()
-
Field Details
-
n
protected final int n -
dimensions
protected final int[] dimensions -
steps
protected final int[] steps -
min
protected final long[] min -
max
protected final long[] max
-
-
Constructor Details
-
Cell
-
-
Method Details
-
getData
Get the basic type array that stores this cells pixels.- Returns:
- underlying basic type array.
-
size
public long size() -
indexToGlobalPosition
public long indexToGlobalPosition(int index, int d) -
indexToGlobalPosition
public void indexToGlobalPosition(int index, long[] position) -
globalPositionToIndex
public int globalPositionToIndex(long[] position) Compute the index in the underlying flat array of this cell which corresponds to the specified globalposition.- Parameters:
position- a global position- Returns:
- corresponding index
-
min
public long min(int d) - Parameters:
d- dimension- Returns:
- minimum
-
min
public void min(long[] minimum) Write the minimum of each dimension into long[].- Parameters:
minimum-
-
dimension
public int dimension(int d) Get the number of pixels in a given dimension d.- Parameters:
d-
-
dimensions
public void dimensions(int[] dim) Write the number of pixels in each dimension into long[].- Parameters:
dim-
-