public class JBIG2ImageReader extends ImageReader
ImageReader| Modifier and Type | Field and Description |
|---|---|
static boolean |
DEBUG |
static boolean |
PERFORMANCE_TEST |
availableLocales, ignoreMetadata, input, locale, minIndex, originatingProvider, progressListeners, seekForwardOnly, updateListeners, warningListeners, warningLocales| Constructor and Description |
|---|
JBIG2ImageReader(ImageReaderSpi originatingProvider) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
canReadRaster() |
JBIG2ReadParam |
getDefaultReadParam() |
JBIG2Globals |
getGlobals()
Returns decoded segments that has been set as globals.
|
int |
getHeight(int imageIndex)
Calculates the height of the specified page.
|
IIOMetadata |
getImageMetadata(int imageIndex)
Simply returns the
JBIG2ImageMetadata. |
Iterator<ImageTypeSpecifier> |
getImageTypes(int imageIndex)
Returns the iterator for available image types.
|
int |
getNumImages(boolean allowSearch) |
IIOMetadata |
getStreamMetadata()
This ImageIO plugin doesn't record
IIOMetadata. |
int |
getWidth(int imageIndex)
Calculates the width of the specified page.
|
JBIG2Globals |
processGlobals(ImageInputStream globalsInputStream)
Decodes and returns the global segments.
|
BufferedImage |
read(int imageIndex,
ImageReadParam param)
Returns the decoded image of specified page considering the given
JBIG2ReadParams. |
Raster |
readRaster(int imageIndex,
ImageReadParam param) |
void |
setGlobals(JBIG2Globals globals)
Simply sets the globals.
|
void |
setInput(Object input,
boolean seekForwardOnly,
boolean ignoreMetadata) |
abort, abortRequested, addIIOReadProgressListener, addIIOReadUpdateListener, addIIOReadWarningListener, checkReadParamBandSettings, clearAbortRequest, computeRegions, dispose, getAspectRatio, getAvailableLocales, getDestination, getFormatName, getImageMetadata, getInput, getLocale, getMinIndex, getNumThumbnails, getOriginatingProvider, getRawImageType, getSourceRegion, getStreamMetadata, getThumbnailHeight, getThumbnailWidth, getTileGridXOffset, getTileGridYOffset, getTileHeight, getTileWidth, hasThumbnails, isIgnoringMetadata, isImageTiled, isRandomAccessEasy, isSeekForwardOnly, processImageComplete, processImageProgress, processImageStarted, processImageUpdate, processPassComplete, processPassStarted, processReadAborted, processSequenceComplete, processSequenceStarted, processThumbnailComplete, processThumbnailPassComplete, processThumbnailPassStarted, processThumbnailProgress, processThumbnailStarted, processThumbnailUpdate, processWarningOccurred, processWarningOccurred, read, readAll, readAll, readAsRenderedImage, readerSupportsThumbnails, readThumbnail, readTile, readTileRaster, removeAllIIOReadProgressListeners, removeAllIIOReadUpdateListeners, removeAllIIOReadWarningListeners, removeIIOReadProgressListener, removeIIOReadUpdateListener, removeIIOReadWarningListener, reset, setInput, setInput, setLocalepublic static final boolean DEBUG
public static final boolean PERFORMANCE_TEST
public JBIG2ImageReader(ImageReaderSpi originatingProvider) throws IOException
originatingProvider - - The ImageReaderSpi that is invoking this constructor, or null.IOException - if something went wrong while reading the provided stream.ImageReader.ImageReader(ImageReaderSpi)public JBIG2ReadParam getDefaultReadParam()
getDefaultReadParam in class ImageReaderImageReader.getDefaultReadParam()public int getWidth(int imageIndex)
throws IOException
getWidth in class ImageReaderimageIndex - - The image index. In this case it is the page number.IOException - if an error occurs reading the width information from the input source.public int getHeight(int imageIndex)
throws IOException
getHeight in class ImageReaderimageIndex - - The image index. In this case it is the page number.0 if an error occurred.IOException - if an error occurs reading the height information from the input source.public IIOMetadata getImageMetadata(int imageIndex) throws IOException
JBIG2ImageMetadata.getImageMetadata in class ImageReaderJBIG2ImageMetadata.IOException - if an error occurs reading the height information from the input source.public Iterator<ImageTypeSpecifier> getImageTypes(int imageIndex) throws IOException
getImageTypes in class ImageReaderimageIndex - - The page number.Iterator for available image types.IOException - if an error occurs reading the height information from the input source.public int getNumImages(boolean allowSearch)
throws IOException
getNumImages in class ImageReaderIOExceptionImageReader.getNumImages(boolean)public IIOMetadata getStreamMetadata()
IIOMetadata.getStreamMetadata in class ImageReadernull at every call.public JBIG2Globals getGlobals() throws IOException
IOException - if an error occurs reading the height information from the input source.public BufferedImage read(int imageIndex, ImageReadParam param) throws IOException
JBIG2ReadParams.read in class ImageReaderIOExceptionImageReader.read(int, ImageReadParam)public boolean canReadRaster()
canReadRaster in class ImageReaderpublic Raster readRaster(int imageIndex, ImageReadParam param) throws IOException
readRaster in class ImageReaderIOExceptionpublic JBIG2Globals processGlobals(ImageInputStream globalsInputStream) throws IOException
globalsInputStream - - The input stream of globals data.JBIG2Globals.IOException - if an error occurs reading the height information from the input source.public void setGlobals(JBIG2Globals globals) throws IOException
globals - - The globals to set.IOException - if an error occurspublic void setInput(Object input, boolean seekForwardOnly, boolean ignoreMetadata)
setInput in class ImageReaderImageReader.setInput(Object, boolean, boolean)Copyright © 2018 The Apache Software Foundation. All rights reserved.