public class RomioPixelBuffer extends AbstractBuffer implements PixelBuffer
PixelBuffer| Modifier and Type | Field and Description |
|---|---|
static int |
MAXIMUM_BUFFER_SIZE
Default maximum buffer size for planar data transfer. (1MB)
|
| Constructor and Description |
|---|
RomioPixelBuffer(String path,
ome.model.core.Pixels pixels)
Creates a new instance.
|
RomioPixelBuffer(String path,
ome.model.core.Pixels pixels,
boolean permitModification)
Creates a new instance, with manual setting of
permitModification. |
| Modifier and Type | Method and Description |
|---|---|
byte[] |
calculateMessageDigest()
Implemented as specified by
PixelBuffer I/F. |
void |
checkBounds(Integer x,
Integer y,
Integer z,
Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
void |
close()
Closes the buffer, cleaning up file state.
|
int |
getByteWidth()
Implemented as specified by
PixelBuffer I/F. |
ome.util.PixelData |
getCol(Integer x,
Integer z,
Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
byte[] |
getColDirect(Integer x,
Integer z,
Integer c,
Integer t,
byte[] buffer)
Implemented as specified by
PixelBuffer I/F. |
Integer |
getColSize()
Implemented as specified by
PixelBuffer I/F. |
ome.util.PixelData |
getHypercube(List<Integer> offset,
List<Integer> size,
List<Integer> step)
Implemented as specified by
PixelBuffer I/F. |
byte[] |
getHypercubeDirect(List<Integer> offset,
List<Integer> size,
List<Integer> step,
byte[] buffer)
Implemented as specified by
PixelBuffer I/F. |
Long |
getHypercubeSize(List<Integer> offset,
List<Integer> size,
List<Integer> step)
Retrieves a the size of a hypercube from this pixel buffer.
|
long |
getId()
Implemented as specified by
PixelBuffer I/F. |
ome.util.PixelData |
getPlane(Integer z,
Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
byte[] |
getPlaneDirect(Integer z,
Integer c,
Integer t,
byte[] buffer)
Implemented as specified by
PixelBuffer I/F. |
Long |
getPlaneOffset(Integer z,
Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
ome.util.PixelData |
getPlaneRegion(Integer x,
Integer y,
Integer width,
Integer height,
Integer z,
Integer c,
Integer t,
Integer stride)
Implemented as specified by
PixelBuffer I/F. |
byte[] |
getPlaneRegionDirect(Integer z,
Integer c,
Integer t,
Integer count,
Integer offset,
byte[] buffer)
Implemented as specified by
PixelBuffer I/F. |
Long |
getPlaneSize()
Implemented as specified by
PixelBuffer I/F. |
ome.util.PixelData |
getRegion(Integer size,
Long offset)
Implemented as specified by
PixelBuffer I/F. |
byte[] |
getRegionDirect(Integer size,
Long offset,
byte[] buffer)
Implemented as specified by
PixelBuffer I/F. |
List<List<Integer>> |
getResolutionDescriptions()
Return a list of lists each of which has sizeX, sizeY for the resolution
level matching the index of the outer index.
|
int |
getResolutionLevel()
Retrieves the active resolution level.
|
int |
getResolutionLevels()
Retrieves the number of resolution levels that the backing
pixels pyramid contains.
|
ome.util.PixelData |
getRow(Integer y,
Integer z,
Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
byte[] |
getRowDirect(Integer y,
Integer z,
Integer c,
Integer t,
byte[] buffer)
Implemented as specified by
PixelBuffer I/F. |
Long |
getRowOffset(Integer y,
Integer z,
Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
Integer |
getRowSize()
Implemented as specified by
PixelBuffer I/F. |
String |
getSha1() |
int |
getSizeC()
Implemented as specified by
PixelBuffer I/F. |
int |
getSizeT()
Implemented as specified by
PixelBuffer I/F. |
int |
getSizeX()
Implemented as specified by
PixelBuffer I/F. |
int |
getSizeY()
Implemented as specified by
PixelBuffer I/F. |
int |
getSizeZ()
Implemented as specified by
PixelBuffer I/F. |
ome.util.PixelData |
getStack(Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
byte[] |
getStackDirect(Integer c,
Integer t,
byte[] buffer)
Implemented as specified by
PixelBuffer I/F. |
Long |
getStackOffset(Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
Long |
getStackSize()
Implemented as specified by
PixelBuffer I/F. |
ome.util.PixelData |
getTile(Integer z,
Integer c,
Integer t,
Integer x,
Integer y,
Integer w,
Integer h)
Retrieves a tile from this pixel buffer.
|
byte[] |
getTileDirect(Integer z,
Integer c,
Integer t,
Integer x,
Integer y,
Integer w,
Integer h,
byte[] buffer)
Retrieves a tile from this pixel buffer.
|
Dimension |
getTileSize()
Retrieves the tile size for the pixel store.
|
ome.util.PixelData |
getTimepoint(Integer t)
Implemented as specified by
PixelBuffer I/F. |
byte[] |
getTimepointDirect(Integer t,
byte[] buffer)
Implemented as specified by
PixelBuffer I/F. |
Long |
getTimepointOffset(Integer t)
Implemented as specified by
PixelBuffer I/F. |
Long |
getTimepointSize()
Implemented as specified by
PixelBuffer I/F. |
Long |
getTotalSize()
Implemented as specified by
PixelBuffer I/F. |
boolean |
isFloat()
Implemented as specified by
PixelBuffer I/F. |
boolean |
isSigned()
Implemented as specified by
PixelBuffer I/F. |
static Integer |
safeLongToInteger(Long v)
Converts a Long value to an Integer safely.
|
void |
setPlane(byte[] buffer,
Integer z,
Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
void |
setPlane(ByteBuffer buffer,
Integer z,
Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
void |
setRegion(Integer size,
Long offset,
byte[] buffer)
Implemented as specified by
PixelBuffer I/F. |
void |
setRegion(Integer size,
Long offset,
ByteBuffer buffer)
Implemented as specified by
PixelBuffer I/F. |
void |
setResolutionLevel(int resolutionLevel)
Sets the active resolution level.
|
void |
setRow(ByteBuffer buffer,
Integer y,
Integer z,
Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
void |
setStack(byte[] buffer,
Integer z,
Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
void |
setStack(ByteBuffer buffer,
Integer z,
Integer c,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
void |
setTile(byte[] buffer,
Integer z,
Integer c,
Integer t,
Integer x,
Integer y,
Integer w,
Integer h)
Sets a tile in this pixel buffer.
|
void |
setTimepoint(byte[] buffer,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
void |
setTimepoint(ByteBuffer buffer,
Integer t)
Implemented as specified by
PixelBuffer I/F. |
getPath, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitgetPathpublic static final int MAXIMUM_BUFFER_SIZE
public RomioPixelBuffer(String path, ome.model.core.Pixels pixels)
permitModification defaults to false.path - The path to the file.pixels - The pixels object to handle.public RomioPixelBuffer(String path, ome.model.core.Pixels pixels, boolean permitModification)
permitModification.path - The path to the file.pixels - The pixels object to handle.public static Integer safeLongToInteger(Long v)
v - Long value to convert.ome.conditions.ApiUsageException - If the conversion would cause an overflow
or an underflow.public void checkBounds(Integer x, Integer y, Integer z, Integer c, Integer t) throws DimensionsOutOfBoundsException
PixelBuffer I/F.checkBounds in interface PixelBufferx - offset across the X-axis of the pixel buffer to check.y - offset across the Y-axis of the pixel buffer to check.z - offset across the Z-axis of the pixel buffer to check.c - offset across the C-axis of the pixel buffer to check.t - offset across the T-axis of the pixel buffer to check.DimensionsOutOfBoundsException - if y,
z, c or t is out of bounds.PixelBuffer.checkBounds(Integer, Integer, Integer, Integer, Integer)public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in interface PixelBufferIOException - if an I/O error occurs.public Long getPlaneSize()
PixelBuffer I/F.getPlaneSize in interface PixelBufferPixelBuffer.getPlaneSize()public Integer getRowSize()
PixelBuffer I/F.getRowSize in interface PixelBufferPixelBuffer.getRowSize()public Integer getColSize()
PixelBuffer I/F.getColSize in interface PixelBufferPixelBuffer.getColSize()public Long getStackSize()
PixelBuffer I/F.getStackSize in interface PixelBufferPixelBuffer.getStackSize()public Long getTimepointSize()
PixelBuffer I/F.getTimepointSize in interface PixelBufferPixelBuffer.getTimepointSize()public Long getTotalSize()
PixelBuffer I/F.getTotalSize in interface PixelBufferPixelBuffer.getTotalSize()public Long getRowOffset(Integer y, Integer z, Integer c, Integer t) throws DimensionsOutOfBoundsException
PixelBuffer I/F.getRowOffset in interface PixelBuffery - offset across the Y-axis of the pixel buffer.z - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getRowOffset(Integer, Integer, Integer, Integer)public Long getPlaneOffset(Integer z, Integer c, Integer t) throws DimensionsOutOfBoundsException
PixelBuffer I/F.getPlaneOffset in interface PixelBufferz - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getPlaneOffset(Integer, Integer, Integer)public Long getStackOffset(Integer c, Integer t) throws DimensionsOutOfBoundsException
PixelBuffer I/F.getStackOffset in interface PixelBufferc - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getStackOffset(Integer, Integer)public Long getTimepointOffset(Integer t) throws DimensionsOutOfBoundsException
PixelBuffer I/F.getTimepointOffset in interface PixelBuffert - offset across the T-axis of the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getTimepointOffset(Integer)public ome.util.PixelData getRegion(Integer size, Long offset) throws IOException
PixelBuffer I/F.getRegion in interface PixelBuffersize - byte width of the region to retrieve.offset - offset within the pixel buffer.order set correctly but not that the
backing buffer will have been byte swapped. The buffer is essentially
directly from disk.IOException - if there is a problem reading from the pixel buffer.PixelBuffer.getRegion(Integer, Long)public byte[] getRegionDirect(Integer size, Long offset, byte[] buffer) throws IOException
PixelBuffer I/F.getRegionDirect in interface PixelBuffersize - byte width of the region to retrieve.offset - offset within the pixel buffer.buffer - pre-allocated buffer of the row's size.buffer containing the data which comprises this
region. It is guaranteed that this buffer will have been byte
swapped. The buffer is essentially directly from disk.IOException - if there is a problem reading from the pixel buffer.PixelBuffer.getRegionDirect(Integer, Long, byte[])public ome.util.PixelData getRow(Integer y, Integer z, Integer c, Integer t) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getRow in interface PixelBuffery - offset across the Y-axis of the pixel buffer.z - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.order set
correctly but not that the backing buffer will have been byte
swapped.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getRow(Integer, Integer, Integer, Integer)public ome.util.PixelData getCol(Integer x, Integer z, Integer c, Integer t) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getCol in interface PixelBufferx - offset across the X-axis of the pixel buffer.z - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.order set
correctly but not that the backing buffer will have been byte
swapped.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getCol(Integer, Integer, Integer, Integer)public byte[] getRowDirect(Integer y, Integer z, Integer c, Integer t, byte[] buffer) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getRowDirect in interface PixelBuffery - offset across the Y-axis of the pixel buffer.z - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.buffer - pre-allocated buffer of the row's size.buffer containing the data which comprises this row
or scanline. It is guaranteed that this buffer will have been byte
swapped.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getRowDirect(Integer, Integer, Integer, Integer, byte[])public byte[] getColDirect(Integer x, Integer z, Integer c, Integer t, byte[] buffer) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getColDirect in interface PixelBufferx - offset across the X-axis of the pixel buffer.z - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.buffer - pre-allocated buffer of the row's size.buffer containing the data which comprises this
column. It is guaranteed that this buffer will have been byte swapped.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getColDirect(Integer, Integer, Integer, Integer, byte[])public ome.util.PixelData getHypercube(List<Integer> offset, List<Integer> size, List<Integer> step) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getHypercube in interface PixelBufferoffset - The offset of each dimension of the pixel buffer.size - The number of pixels to retrieve along each dimension .step - The step size across each dimension .IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsExceptionPixelBuffer#getHypercube(List, IList, List) public byte[] getHypercubeDirect(List<Integer> offset, List<Integer> size, List<Integer> step, byte[] buffer) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getHypercubeDirect in interface PixelBufferoffset - The offset of each dimension of the pixel buffer.size - The number of pixels to retrieve along each dimension .step - The step size across each dimension .buffer - pre-allocated buffer, count in size.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsExceptionPixelBuffer#getHypercubeDirect(List, IList, List, byte[]) public byte[] getPlaneRegionDirect(Integer z, Integer c, Integer t, Integer count, Integer offset, byte[] buffer) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getPlaneRegionDirect in interface PixelBufferz - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.count - the number of pixels to retrieve.offset - the offset at which to retrieve count pixels.buffer - pre-allocated buffer, count in size.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsExceptionPixelBuffer.getPlaneRegionDirect(Integer, Integer, Integer, Integer,
Integer, byte[])public ome.util.PixelData getPlane(Integer z, Integer c, Integer t) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getPlane in interface PixelBufferz - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.order set
correctly but not that the backing buffer will have been byte
swapped.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getPlane(Integer, Integer, Integer)public ome.util.PixelData getPlaneRegion(Integer x, Integer y, Integer width, Integer height, Integer z, Integer c, Integer t, Integer stride) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getPlaneRegion in interface PixelBufferx - offset across the X-axis of the pixel buffer.y - offset across the Y-axis of the pixel buffer.width - The number of pixels to retrieve along the X-axis.height - The number of pixels to retrieve along the Y-axis.z - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.stride - The step size.order set
correctly but not that the backing buffer will have been byte
swapped.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getPlaneRegion(Integer, Integer, Integer, Integer,
Integer, Integer, Integer, Integer)public byte[] getPlaneDirect(Integer z, Integer c, Integer t, byte[] buffer) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getPlaneDirect in interface PixelBufferz - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.buffer - pre-allocated buffer of the plane's size.buffer containing the data which comprises this 2D
image plane. It is guaranteed that this buffer will have been byte
swapped.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getPlaneDirect(Integer, Integer, Integer, byte[])public ome.util.PixelData getStack(Integer c, Integer t) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getStack in interface PixelBufferc - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.order set
correctly but not that the backing buffer will have been byte
swapped.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getStack(Integer, Integer)public byte[] getStackDirect(Integer c, Integer t, byte[] buffer) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getStackDirect in interface PixelBufferc - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.buffer - pre-allocated buffer of the stack's size.buffer containing the data which comprises this
stack. It is guaranteed that this buffer will have been byte swapped.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getStackDirect(Integer, Integer, byte[])public ome.util.PixelData getTimepoint(Integer t) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getTimepoint in interface PixelBuffert - offset across the T-axis of the pixel buffer.order set
correctly but not that the backing buffer will have been byte
swapped.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getTimepoint(Integer)public byte[] getTimepointDirect(Integer t, byte[] buffer) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.getTimepointDirect in interface PixelBuffert - offset across the T-axis of the pixel buffer.buffer - pre-allocated buffer of the timepoint's size.buffer containing the data which comprises this
timepoint. It is guaranteed that this buffer will have been byte swapped.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.getTimepointDirect(Integer, byte[])public void setRegion(Integer size, Long offset, byte[] buffer) throws IOException
PixelBuffer I/F.setRegion in interface PixelBuffersize - byte width of the region to set.offset - offset within the pixel buffer.buffer - a byte array of the data.IOException - if there is a problem writing to the pixel buffer.PixelBuffer.setRegion(Integer, Long, byte[])public void setRegion(Integer size, Long offset, ByteBuffer buffer) throws IOException
PixelBuffer I/F.setRegion in interface PixelBuffersize - byte width of the region to set.offset - offset within the pixel buffer.buffer - a byte buffer of the data.IOException - if there is a problem writing to the pixel buffer.PixelBuffer.setRegion(Integer, Long, ByteBuffer)public void setRow(ByteBuffer buffer, Integer y, Integer z, Integer c, Integer t) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.setRow in interface PixelBufferbuffer - a byte buffer of the data comprising this row or scanline.y - offset across the Y-axis of the pixel buffer.z - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.IOException - if there is a problem reading from the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.setRow(ByteBuffer, Integer, Integer, Integer, Integer)public void setPlane(ByteBuffer buffer, Integer z, Integer c, Integer t) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.setPlane in interface PixelBufferbuffer - a byte array of the data comprising this 2D image plane.z - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.IOException - if there is a problem writing to the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.setPlane(ByteBuffer, Integer, Integer, Integer)public void setPlane(byte[] buffer,
Integer z,
Integer c,
Integer t)
throws IOException,
DimensionsOutOfBoundsException
PixelBuffer I/F.setPlane in interface PixelBufferbuffer - a byte buffer of the data comprising this 2D image plane.z - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.IOException - if there is a problem writing to the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.setPlane(byte[], Integer, Integer, Integer)public void setStack(ByteBuffer buffer, Integer z, Integer c, Integer t) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.setStack in interface PixelBufferbuffer - a byte buffer of the data comprising this stack.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.IOException - if there is a problem writing to the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.setStack(ByteBuffer, Integer, Integer, Integer)public void setStack(byte[] buffer,
Integer z,
Integer c,
Integer t)
throws IOException,
DimensionsOutOfBoundsException
PixelBuffer I/F.setStack in interface PixelBufferbuffer - a byte array of the data comprising this stack.z - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.IOException - if there is a problem writing to the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.setStack(byte[], Integer, Integer, Integer)public void setTimepoint(ByteBuffer buffer, Integer t) throws IOException, DimensionsOutOfBoundsException
PixelBuffer I/F.setTimepoint in interface PixelBufferbuffer - a byte buffer of the data comprising this timepoint.t - offset across the T-axis of the pixel buffer.IOException - if there is a problem writing to the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.setTimepoint(ByteBuffer, Integer)public void setTimepoint(byte[] buffer,
Integer t)
throws IOException,
DimensionsOutOfBoundsException
PixelBuffer I/F.setTimepoint in interface PixelBufferbuffer - a byte array of the data comprising this timepoint.t - offset across the T-axis of the pixel buffer.IOException - if there is a problem writing to the pixel buffer.DimensionsOutOfBoundsException - if offsets are out of bounds
after checking with checkBounds().PixelBuffer.setTimepoint(ByteBuffer, Integer)public byte[] calculateMessageDigest()
throws IOException
PixelBuffer I/F.calculateMessageDigest in interface PixelBufferIOException - if there is a problem reading from the pixel buffer.PixelBuffer.calculateMessageDigest()public int getByteWidth()
PixelBuffer I/F.getByteWidth in interface PixelBufferPixelBuffer.getByteWidth()public boolean isSigned()
PixelBuffer I/F.isSigned in interface PixelBufferPixelBuffer.isSigned()public boolean isFloat()
PixelBuffer I/F.isFloat in interface PixelBufferPixelBuffer.isFloat()public int getSizeC()
PixelBuffer I/F.getSizeC in interface PixelBufferPixelBuffer.getSizeC()public int getSizeT()
PixelBuffer I/F.getSizeT in interface PixelBufferPixelBuffer.getSizeT()public int getSizeX()
PixelBuffer I/F.getSizeX in interface PixelBufferPixelBuffer.getSizeX()public int getSizeY()
PixelBuffer I/F.getSizeY in interface PixelBufferPixelBuffer.getSizeY()public int getSizeZ()
PixelBuffer I/F.getSizeZ in interface PixelBufferPixelBuffer.getSizeZ()public long getId()
PixelBuffer I/F.getId in interface PixelBufferPixelBuffer.getId()public String getSha1()
public ome.util.PixelData getTile(Integer z, Integer c, Integer t, Integer x, Integer y, Integer w, Integer h) throws IOException
PixelBuffergetTile in interface PixelBufferz - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.x - Top left corner of the tile, X offset.y - Top left corner of the tile, Y offset.w - Width of the tile.h - Height of the tile.IOException - if there is a problem reading from the pixel buffer.getTileDirect()public byte[] getTileDirect(Integer z, Integer c, Integer t, Integer x, Integer y, Integer w, Integer h, byte[] buffer) throws IOException
PixelBuffergetTileDirect in interface PixelBufferz - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.x - Top left corner of the tile, X offset.y - Top left corner of the tile, Y offset.w - Width of the tile.h - Height of the tile.buffer - Pre-allocated buffer of the tile's size.buffer containing the data which comprises this
region. It is guaranteed that this buffer will have been byte
swapped. The buffer is essentially directly from disk.IOException - if there is a problem reading from the pixel buffer.getTile()public void setTile(byte[] buffer,
Integer z,
Integer c,
Integer t,
Integer x,
Integer y,
Integer w,
Integer h)
throws IOException,
BufferOverflowException
PixelBuffersetTile in interface PixelBufferbuffer - A byte array of the data.z - offset across the Z-axis of the pixel buffer.c - offset across the C-axis of the pixel buffer.t - offset across the T-axis of the pixel buffer.x - Top left corner of the tile, X offset.y - Top left corner of the tile, Y offset.w - Width of the tile.h - Height of the tile.IOException - if there is a problem writing to the pixel buffer.BufferOverflowException - if an attempt is made to write off the
end of the file.public int getResolutionLevel()
PixelBuffergetResolutionLevel in interface PixelBufferpublic int getResolutionLevels()
PixelBuffergetResolutionLevels in interface PixelBufferpublic List<List<Integer>> getResolutionDescriptions()
PixelBuffergetResolutionDescriptions in interface PixelBufferpublic Dimension getTileSize()
PixelBuffergetTileSize in interface PixelBuffernull if the pixel
buffer is not tiled.public void setResolutionLevel(int resolutionLevel)
PixelBuffersetResolutionLevel in interface PixelBufferresolutionLevel - The resolution level to be used by
the pixel buffer.public Long getHypercubeSize(List<Integer> offset, List<Integer> size, List<Integer> step) throws DimensionsOutOfBoundsException
PixelBuffergetHypercubeSize in interface PixelBufferoffset - The offset of each dimension of the pixel buffer.size - The number of pixels to retrieve along each dimension .step - The step size across each dimension .DimensionsOutOfBoundsException
Version: 5.1.1-ice35-b43
Copyright © 2015 The University of Dundee & Open Microscopy Environment. All Rights Reserved.