| java.lang.Object javax.media.jai.PlanarImage javax.media.jai.OpImage javax.media.jai.PointOpImage javax.media.jai.NullOpImage
All known Subclasses: com.sun.media.jai.util.DisposableNullOpImage, com.sun.media.jai.opimage.PointMapperOpImage,
NullOpImage | public class NullOpImage extends PointOpImage (Code) | | A trivial OpImage subclass that simply transmits its
source unchanged. This may be useful when an interface requires an
OpImage but another sort of RenderedImage
(such as a BufferedImage or TiledImage )
is available. Additionally, NullOpImage is able to
make use of JAI's tile caching mechanisms.
Methods that get or set properties are implemented to forward
the requests to the source image; no independent property information
is stored in the NullOpImage itself.
See Also: PointOpImage |
Method Summary | |
public Raster | computeTile(int tileX, int tileY) Returns a tile for reading.
Parameters: tileX - The X index of the tile. Parameters: tileY - The Y index of the tile. | public boolean | computesUniqueTiles() Returns false as NullOpImage can return via computeTile()
tiles that are internally cached. | public int | getOperationComputeType() Returns one of OP_COMPUTE_BOUND, OP_IO_BOUND, or
OP_NETWORK_BOUND to indicate how the operation is likely to
spend its time. | protected synchronized Hashtable | getProperties() Returns the properties from the source image. | public Object | getProperty(String name) Retrieves a property from the source image by name or
java.awt.Image.UndefinedProperty if the property
with the specified name is not defined. | public Class | getPropertyClass(String name) Returns the class of the specified property from the source image. | public String[] | getPropertyNames() Returns the property names from the source image or null
if no property names are recognized. | public String[] | getPropertyNames(String prefix) Returns the property names with the supplied prefix from
the source image or null if no property names
are recognized. | public void | removeProperty(String name) Removes a property from the source image by name. | protected synchronized void | setProperties(Hashtable properties) Set the properties Hashtable of the source image
to the supplied Hashtable . | public void | setProperty(String name, Object value) Sets a property on the source image by name. |
computeType | protected int computeType(Code) | | |
NullOpImage | public NullOpImage(RenderedImage source, ImageLayout layout, Map configuration, int computeType)(Code) | | Constructs a NullOpImage . The superclass
constructor will be passed a new ImageLayout
object with all of its fields filled in. The ColorModel
may be overridden via the supplied ImageLayout ; all
other layout fields are derived from the source image. Any
specified ColorModel will be used if and only if it
is compatible with the source image SampleModel .
Parameters: layout - An ImageLayout optionally specifyingthe image ColorModel ; all other fields areignored. This parameter may be null . Parameters: source - A RenderedImage ; must not benull or a IllegalArgumentException will be thrown. Parameters: configuration - Configurable attributes of the image includingconfiguration variables indexed byRenderingHints.Key s and image properties indexedby String s or CaselessStringKey s.This is simply forwarded to the superclass constructor. Parameters: computeType - A tag indicating whether the sourceis OpImage.OP_COMPUTE_BOUND ,OpImage.OP_IO_BOUND orOpImage.OP_NETWORK_BOUND . This information isused as a hint to optimize OpImage computation. IllegalArgumentException if source is null . IllegalArgumentException if computeType is not one of the known OP_*_BOUND values. since: JAI 1.1 |
NullOpImage | public NullOpImage(RenderedImage source, TileCache cache, int computeType, ImageLayout layout)(Code) | | Constructs a NullOpImage . The superclass
constructor will be passed a new ImageLayout
object with all of its fields filled in. The ColorModel
may be overridden via the supplied ImageLayout ; all
other layout fields are derived from the source image. Any
specified ColorModel will be used if and only if it
is compatible with the source image SampleModel .
Parameters: source - A RenderedImage ; must not benull or a IllegalArgumentException will be thrown. Parameters: cache - a TileCache object to store tiles from this OpImage,or null. If null, a default cache will be used. Parameters: computeType - A tag indicating whether the sourceis OpImage.OP_COMPUTE_BOUND ,OpImage.OP_IO_BOUND orOpImage.OP_NETWORK_BOUND . This information isused as a hint to optimize OpImage computation. Parameters: layout - An ImageLayout optionally specifyingthe image ColorModel ; all other fields areignored. This parameter may be null . throws: IllegalArgumentException - if source is null . throws: IllegalArgumentException - if computeType is not one of the known OP_*_BOUND values. |
computeTile | public Raster computeTile(int tileX, int tileY)(Code) | | Returns a tile for reading.
Parameters: tileX - The X index of the tile. Parameters: tileY - The Y index of the tile. The tile as a Raster . |
computesUniqueTiles | public boolean computesUniqueTiles()(Code) | | Returns false as NullOpImage can return via computeTile()
tiles that are internally cached.
|
getOperationComputeType | public int getOperationComputeType()(Code) | | Returns one of OP_COMPUTE_BOUND, OP_IO_BOUND, or
OP_NETWORK_BOUND to indicate how the operation is likely to
spend its time. The answer does not affect the output of the
operation, but may allow a scheduler to parallelize the
computation of multiple operations more effectively. The
default implementation returns OP_COMPUTE_BOUND.
|
getProperties | protected synchronized Hashtable getProperties()(Code) | | Returns the properties from the source image.
|
getProperty | public Object getProperty(String name)(Code) | | Retrieves a property from the source image by name or
java.awt.Image.UndefinedProperty if the property
with the specified name is not defined.
|
getPropertyClass | public Class getPropertyClass(String name)(Code) | | Returns the class of the specified property from the source image.
since: JAI 1.1 |
getPropertyNames | public String[] getPropertyNames()(Code) | | Returns the property names from the source image or null
if no property names are recognized.
|
getPropertyNames | public String[] getPropertyNames(String prefix)(Code) | | Returns the property names with the supplied prefix from
the source image or null if no property names
are recognized.
|
removeProperty | public void removeProperty(String name)(Code) | | Removes a property from the source image by name.
since: JAI 1.1 |
setProperties | protected synchronized void setProperties(Hashtable properties)(Code) | | Set the properties Hashtable of the source image
to the supplied Hashtable .
|
setProperty | public void setProperty(String name, Object value)(Code) | | Sets a property on the source image by name.
|
Methods inherited from javax.media.jai.OpImage | protected void addTileToCache(int tileX, int tileY, Raster tile)(Code)(Java Doc) public void cancelTiles(TileRequest request, Point[] tileIndices)(Code)(Java Doc) static Vector checkSourceVector(Vector sources, boolean checkElements)(Code)(Java Doc) protected void computeRect(Raster[] sources, WritableRaster dest, Rectangle destRect)(Code)(Java Doc) protected void computeRect(PlanarImage[] sources, WritableRaster dest, Rectangle destRect)(Code)(Java Doc) public Raster computeTile(int tileX, int tileY)(Code)(Java Doc) public boolean computesUniqueTiles()(Code)(Java Doc) final protected WritableRaster createTile(int tileX, int tileY)(Code)(Java Doc) public synchronized void dispose()(Code)(Java Doc) public static int getExpandedNumBands(SampleModel sampleModel, ColorModel colorModel)(Code)(Java Doc) protected synchronized RasterFormatTag[] getFormatTags()(Code)(Java Doc) public int getOperationComputeType()(Code)(Java Doc) public Raster getTile(int tileX, int tileY)(Code)(Java Doc) public TileCache getTileCache()(Code)(Java Doc) public Object getTileCacheMetric()(Code)(Java Doc) public Point[] getTileDependencies(int tileX, int tileY, int sourceIndex)(Code)(Java Doc) protected Raster getTileFromCache(int tileX, int tileY)(Code)(Java Doc) public TileRecycler getTileRecycler()(Code)(Java Doc) public Raster[] getTiles(Point[] tileIndices)(Code)(Java Doc) public boolean hasExtender(int sourceIndex)(Code)(Java Doc) public Point2D mapDestPoint(Point2D destPt, int sourceIndex)(Code)(Java Doc) abstract public Rectangle mapDestRect(Rectangle destRect, int sourceIndex)(Code)(Java Doc) public Point2D mapSourcePoint(Point2D sourcePt, int sourceIndex)(Code)(Java Doc) abstract public Rectangle mapSourceRect(Rectangle sourceRect, int sourceIndex)(Code)(Java Doc) public void prefetchTiles(Point[] tileIndices)(Code)(Java Doc) public TileRequest queueTiles(Point[] tileIndices)(Code)(Java Doc) protected void recycleTile(Raster tile)(Code)(Java Doc) public void setTileCache(TileCache cache)(Code)(Java Doc) protected static Vector vectorize(RenderedImage image)(Code)(Java Doc) protected static Vector vectorize(RenderedImage image1, RenderedImage image2)(Code)(Java Doc) protected static Vector vectorize(RenderedImage image1, RenderedImage image2, RenderedImage image3)(Code)(Java Doc)
|
Methods inherited from javax.media.jai.PlanarImage | public static int XToTileX(int x, int tileGridXOffset, int tileWidth)(Code)(Java Doc) public int XToTileX(int x)(Code)(Java Doc) public static int YToTileY(int y, int tileGridYOffset, int tileHeight)(Code)(Java Doc) public int YToTileY(int y)(Code)(Java Doc) public void addPropertyChangeListener(PropertyChangeListener listener)(Code)(Java Doc) public void addPropertyChangeListener(String propertyName, PropertyChangeListener listener)(Code)(Java Doc) public synchronized boolean addSink(Object sink)(Code)(Java Doc) protected void addSink(PlanarImage sink)(Code)(Java Doc) protected void addSource(Object source)(Code)(Java Doc) public synchronized void addTileComputationListener(TileComputationListener listener)(Code)(Java Doc) public void cancelTiles(TileRequest request, Point[] tileIndices)(Code)(Java Doc) public WritableRaster copyData()(Code)(Java Doc) public WritableRaster copyData(WritableRaster raster)(Code)(Java Doc) public void copyExtendedData(WritableRaster dest, BorderExtender extender)(Code)(Java Doc) public static ColorModel createColorModel(SampleModel sm)(Code)(Java Doc) public PlanarImage createSnapshot()(Code)(Java Doc) final protected WritableRaster createWritableRaster(SampleModel sampleModel, Point location)(Code)(Java Doc) public synchronized void dispose()(Code)(Java Doc) protected void finalize() throws Throwable(Code)(Java Doc) public BufferedImage getAsBufferedImage(Rectangle rect, ColorModel cm)(Code)(Java Doc) public BufferedImage getAsBufferedImage()(Code)(Java Doc) public Rectangle getBounds()(Code)(Java Doc) public ColorModel getColorModel()(Code)(Java Doc) public Raster getData()(Code)(Java Doc) public Raster getData(Rectangle region)(Code)(Java Doc) public static ColorModel getDefaultColorModel(int dataType, int numBands)(Code)(Java Doc) public Raster getExtendedData(Rectangle region, BorderExtender extender)(Code)(Java Doc) public Graphics getGraphics()(Code)(Java Doc) public int getHeight()(Code)(Java Doc) public Object getImageID()(Code)(Java Doc) public int getMaxTileX()(Code)(Java Doc) public int getMaxTileY()(Code)(Java Doc) public int getMaxX()(Code)(Java Doc) public int getMaxY()(Code)(Java Doc) public int getMinTileX()(Code)(Java Doc) public int getMinTileY()(Code)(Java Doc) public int getMinX()(Code)(Java Doc) public int getMinY()(Code)(Java Doc) public int getNumBands()(Code)(Java Doc) public int getNumSources()(Code)(Java Doc) public int getNumXTiles()(Code)(Java Doc) public int getNumYTiles()(Code)(Java Doc) protected Hashtable getProperties()(Code)(Java Doc) public Object getProperty(String name)(Code)(Java Doc) public Class getPropertyClass(String name)(Code)(Java Doc) public String[] getPropertyNames()(Code)(Java Doc) public String[] getPropertyNames(String prefix)(Code)(Java Doc) public SampleModel getSampleModel()(Code)(Java Doc) public Vector getSinks()(Code)(Java Doc) public PlanarImage getSource(int index)(Code)(Java Doc) public PlanarImage getSourceImage(int index)(Code)(Java Doc) public Object getSourceObject(int index)(Code)(Java Doc) public Vector getSources()(Code)(Java Doc) public void getSplits(IntegerSequence xSplits, IntegerSequence ySplits, Rectangle rect)(Code)(Java Doc) abstract public Raster getTile(int tileX, int tileY)(Code)(Java Doc) public TileComputationListener[] getTileComputationListeners()(Code)(Java Doc) public TileFactory getTileFactory()(Code)(Java Doc) public int getTileGridXOffset()(Code)(Java Doc) public int getTileGridYOffset()(Code)(Java Doc) public int getTileHeight()(Code)(Java Doc) public Point[] getTileIndices(Rectangle region)(Code)(Java Doc) public Rectangle getTileRect(int tileX, int tileY)(Code)(Java Doc) public int getTileWidth()(Code)(Java Doc) public Raster[] getTiles(Point[] tileIndices)(Code)(Java Doc) public Raster[] getTiles()(Code)(Java Doc) public int getWidth()(Code)(Java Doc) public boolean overlapsMultipleTiles(Rectangle rect)(Code)(Java Doc) public void prefetchTiles(Point[] tileIndices)(Code)(Java Doc) public TileRequest queueTiles(Point[] tileIndices)(Code)(Java Doc) public void removeProperty(String name)(Code)(Java Doc) public void removePropertyChangeListener(PropertyChangeListener listener)(Code)(Java Doc) public void removePropertyChangeListener(String propertyName, PropertyChangeListener listener)(Code)(Java Doc) public synchronized boolean removeSink(Object sink)(Code)(Java Doc) protected boolean removeSink(PlanarImage sink)(Code)(Java Doc) public void removeSinks()(Code)(Java Doc) protected boolean removeSource(Object source)(Code)(Java Doc) protected void removeSources()(Code)(Java Doc) public synchronized void removeTileComputationListener(TileComputationListener listener)(Code)(Java Doc) protected void setImageLayout(ImageLayout layout)(Code)(Java Doc) protected void setProperties(Hashtable properties)(Code)(Java Doc) public void setProperty(String name, Object value)(Code)(Java Doc) protected void setSource(Object source, int index)(Code)(Java Doc) protected void setSources(List sourceList)(Code)(Java Doc) public static int tileXToX(int tx, int tileGridXOffset, int tileWidth)(Code)(Java Doc) public int tileXToX(int tx)(Code)(Java Doc) public static int tileYToY(int ty, int tileGridYOffset, int tileHeight)(Code)(Java Doc) public int tileYToY(int ty)(Code)(Java Doc) public String toString()(Code)(Java Doc) public static PlanarImage wrapRenderedImage(RenderedImage image)(Code)(Java Doc)
|
|
|