Class RawRenderedImage
- java.lang.Object
-
- com.github.jaiimageio.impl.common.SimpleRenderedImage
-
- com.github.jaiimageio.impl.plugins.raw.RawRenderedImage
-
- All Implemented Interfaces:
java.awt.image.RenderedImage
public class RawRenderedImage extends SimpleRenderedImage
-
-
Field Summary
Fields Modifier and Type Field Description private java.awt.image.Raster
currentTile
private java.awt.Point
currentTileGrid
private java.awt.image.BufferedImage
destImage
private int[]
destinationBands
private java.awt.Rectangle
destinationRegion
The destination bounds.private RawImageInputStream
iis
The input stream we read fromprivate int
imageIndex
private int
maxXTile
private int
maxYTile
private int
nComp
private boolean
noTransform
Coordinate transform is not needed from the source (image stream) to the destination.private java.awt.Dimension
originalDimension
private int
originalNumXTiles
The orginal number tiles in X direction.private java.awt.Rectangle
originalRegion
private java.awt.image.SampleModel
originalSampleModel
The sample model for the original image.private javax.imageio.ImageReadParam
param
TheImageReadParam
to create thisrenderedImage
.private long
position
The position of the first sample of this image in the stream.private java.awt.image.WritableRaster
rasForATile
The raster for medialib tiles to share.private RawImageReader
reader
Caches theRawImageReader
which creates this object.private int
scaleX
The subsampling parameters.private int
scaleY
The subsampling parameters.private int[]
sourceBands
private java.awt.Point
sourceOrigin
private long
tileDataSize
cache the size of the data for each tile in the stream.private int
xOffset
The subsampling parameters.private int
yOffset
The subsampling parameters.-
Fields inherited from class com.github.jaiimageio.impl.common.SimpleRenderedImage
colorModel, height, minX, minY, properties, sampleModel, sources, tileGridXOffset, tileGridYOffset, tileHeight, tileWidth, width
-
-
Constructor Summary
Constructors Constructor Description RawRenderedImage(RawImageInputStream iis, RawImageReader reader, javax.imageio.ImageReadParam param, int imageIndex)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clearDestImage()
private int
clip(int value, int min, int max)
java.awt.image.Raster
getTile(int tileX, int tileY)
private int
getTileNum(int x, int y)
void
readAsRaster(java.awt.image.WritableRaster raster)
private java.awt.image.Raster
readSubsampledRaster(java.awt.image.WritableRaster raster)
void
setDestImage(java.awt.image.BufferedImage image)
-
Methods inherited from class com.github.jaiimageio.impl.common.SimpleRenderedImage
copyData, getBounds, getColorModel, getData, getData, getHeight, getMaxTileX, getMaxTileY, getMaxX, getMaxY, getMinTileX, getMinTileY, getMinX, getMinY, getNumXTiles, getNumYTiles, getProperty, getPropertyNames, getPropertyNames, getSampleModel, getSources, getTileGridXOffset, getTileGridYOffset, getTileHeight, getTileWidth, getWidth, tileXToX, tileXToX, tileYToY, tileYToY, XToTileX, XToTileX, YToTileY, YToTileY
-
-
-
-
Field Detail
-
originalSampleModel
private java.awt.image.SampleModel originalSampleModel
The sample model for the original image.
-
currentTile
private java.awt.image.Raster currentTile
-
currentTileGrid
private java.awt.Point currentTileGrid
-
iis
private RawImageInputStream iis
The input stream we read from
-
reader
private RawImageReader reader
Caches theRawImageReader
which creates this object. This variable is used to monitor the abortion.
-
param
private javax.imageio.ImageReadParam param
TheImageReadParam
to create thisrenderedImage
.
-
imageIndex
private int imageIndex
-
destinationRegion
private java.awt.Rectangle destinationRegion
The destination bounds.
-
originalRegion
private java.awt.Rectangle originalRegion
-
sourceOrigin
private java.awt.Point sourceOrigin
-
originalDimension
private java.awt.Dimension originalDimension
-
maxXTile
private int maxXTile
-
maxYTile
private int maxYTile
-
scaleX
private int scaleX
The subsampling parameters.
-
scaleY
private int scaleY
The subsampling parameters.
-
xOffset
private int xOffset
The subsampling parameters.
-
yOffset
private int yOffset
The subsampling parameters.
-
destinationBands
private int[] destinationBands
-
sourceBands
private int[] sourceBands
-
nComp
private int nComp
-
noTransform
private boolean noTransform
Coordinate transform is not needed from the source (image stream) to the destination.
-
rasForATile
private java.awt.image.WritableRaster rasForATile
The raster for medialib tiles to share.
-
destImage
private java.awt.image.BufferedImage destImage
-
position
private long position
The position of the first sample of this image in the stream.
-
tileDataSize
private long tileDataSize
cache the size of the data for each tile in the stream.
-
originalNumXTiles
private int originalNumXTiles
The orginal number tiles in X direction.
-
-
Constructor Detail
-
RawRenderedImage
public RawRenderedImage(RawImageInputStream iis, RawImageReader reader, javax.imageio.ImageReadParam param, int imageIndex) throws java.io.IOException
- Throws:
java.io.IOException
-
-
Method Detail
-
getTile
public java.awt.image.Raster getTile(int tileX, int tileY)
-
readAsRaster
public void readAsRaster(java.awt.image.WritableRaster raster) throws java.io.IOException
- Throws:
java.io.IOException
-
readSubsampledRaster
private java.awt.image.Raster readSubsampledRaster(java.awt.image.WritableRaster raster) throws java.io.IOException
- Throws:
java.io.IOException
-
setDestImage
public void setDestImage(java.awt.image.BufferedImage image)
-
clearDestImage
public void clearDestImage()
-
getTileNum
private int getTileNum(int x, int y)
-
clip
private int clip(int value, int min, int max)
-
-