public interface JPEGTurboService
extends loci.common.services.Service
Modifier and Type | Method and Description |
---|---|
void |
close()
Free resources associated with the initialized stream.
|
byte[] |
getCompressedTile(byte[] data,
int xTile,
int yTile)
Similar to getTile(int, int), but returns the JPEG-compressed bytes.
|
byte[] |
getCompressedTile(int xTile,
int yTile)
Similar to getTile(int, int), but returns the JPEG-compressed bytes.
|
long[] |
getRestartMarkers() |
byte[] |
getTile(byte[] buf,
int xCoordinate,
int yCoordinate,
int width,
int height)
Get the uncompressed bytes representing the given bounding box.
|
byte[] |
getTile(int xTile,
int yTile)
Get the uncompressed bytes representing the given tile index.
|
int |
getTileColumns() |
int |
getTileHeight() |
int |
getTileRows() |
int |
getTileWidth() |
void |
initialize(loci.common.RandomAccessInputStream jpeg,
int width,
int height)
Initialize the given stream, which represents an image of the given
width and height.
|
boolean |
isLibraryLoaded() |
void |
setRestartMarkers(long[] markers) |
long[] getRestartMarkers()
void setRestartMarkers(long[] markers)
markers
- precalculated restart markers associated with
the current JPEG streamvoid initialize(loci.common.RandomAccessInputStream jpeg, int width, int height) throws loci.common.services.ServiceException, java.io.IOException
jpeg
- open stream containing JPEG datawidth
- total image widthheight
- total image heightloci.common.services.ServiceException
java.io.IOException
int getTileWidth()
int getTileHeight()
int getTileRows()
int getTileColumns()
byte[] getTile(byte[] buf, int xCoordinate, int yCoordinate, int width, int height) throws java.io.IOException
buf
- array in which to store uncompressed bytesxCoordinate
- upper-left X coordinate of bounding boxyCoordinate
- upper-left Y coordinate of bounding boxwidth
- width of bounding boxheight
- height of bounding boxjava.io.IOException
byte[] getTile(int xTile, int yTile) throws java.io.IOException
xTile
- column index of the tileyTile
- row index of the tilejava.io.IOException
byte[] getCompressedTile(int xTile, int yTile) throws java.io.IOException
xTile
- column index of the tileyTile
- row index of the tilejava.io.IOException
byte[] getCompressedTile(byte[] data, int xTile, int yTile) throws java.io.IOException
data
- preallocated array for storing tilexTile
- column index of the tileyTile
- row index of the tilejava.io.IOException
void close() throws java.io.IOException
java.io.IOException
boolean isLibraryLoaded()
Copyright © 2024 Open Microscopy Environment