| java.lang.Object javax.media.jai.PlanarImage javax.media.jai.OpImage javax.media.jai.PointOpImage
All known Subclasses: com.sun.media.jai.opimage.ColorQuantizerOpImage, com.sun.media.jai.mlib.MlibInvertOpImage, com.sun.media.jai.mlib.MlibClampOpImage, com.sun.media.jai.mlib.MlibSubtractOpImage, ca.forklabs.media.jai.opimage.MedianCollectionOpImage, com.sun.media.jai.mlib.MlibAndOpImage, com.sun.media.jai.mlib.MlibLogOpImage, com.sun.media.jai.opimage.CompositeNoDestAlphaOpImage, com.sun.media.jai.mlib.MlibOrOpImage, com.sun.media.jai.opimage.BandCombineOpImage, com.sun.media.jai.opimage.ComplexArithmeticOpImage, com.sun.media.jai.mlib.MlibBinarizeOpImage, com.sun.media.jai.mlib.MlibDivideIntoConstOpImage, com.sun.media.jai.opimage.ClampOpImage, com.sun.media.jai.opimage.ConjugateOpImage, com.sun.media.jai.mlib.MlibOrConstOpImage, com.sun.media.jai.opimage.CropOpImage, com.sun.media.jai.mlib.MlibMultiplyConstOpImage, com.sun.media.jai.mlib.MlibLookupOpImage, com.sun.media.jai.opimage.XorOpImage, com.sun.media.jai.mlib.MlibAddOpImage, com.sun.media.jai.mlib.MlibBandSelectOpImage, com.sun.media.jai.opimage.AndOpImage, com.sun.media.jai.mlib.MlibCopyOpImage, com.sun.media.jai.opimage.AddOpImage, com.sun.media.jai.opimage.OrOpImage, com.sun.media.jai.opimage.AddCollectionOpImage, com.sun.media.jai.mlib.MlibAndConstOpImage, com.sun.media.jai.opimage.OrderedDitherOpImage, com.sun.media.jai.mlib.MlibAbsoluteOpImage, com.sun.media.jai.opimage.MaxOpImage, com.sun.media.jai.opimage.MagnitudePhaseOpImage, com.sun.media.jai.opimage.PolarToComplexOpImage, com.sun.media.jai.opimage.OverlayOpImage, com.sun.media.jai.mlib.MlibXorConstOpImage, com.sun.media.jai.mlib.MlibDivideOpImage, com.sun.media.jai.opimage.DivideOpImage, javax.media.jai.ColormapOpImage, com.sun.media.jai.mlib.MlibSubtractFromConstOpImage, com.sun.media.jai.opimage.MultiplyOpImage, com.sun.media.jai.opimage.ColorConvertOpImage, com.sun.media.jai.mlib.MlibCompositeOpImage, com.sun.media.jai.mlib.MlibBandCombineOpImage, com.sun.media.jai.mlib.MlibNotOpImage, com.sun.media.jai.opimage.BandSelectOpImage, com.sun.media.jai.opimage.AbsoluteOpImage, com.sun.media.jai.mlib.MlibExpOpImage, com.sun.media.jai.mlib.MlibThresholdOpImage, com.sun.media.jai.opimage.CompositeOpImage, com.sun.media.jai.mlib.MlibMinOpImage, com.sun.media.jai.mlib.MlibOrderedDitherOpImage, javax.media.jai.NullOpImage, com.sun.media.jai.mlib.MlibMaxOpImage, com.sun.media.jai.opimage.BandMergeOpImage, com.sun.media.jai.mlib.MlibXorOpImage, com.sun.media.jai.opimage.BinarizeOpImage, com.sun.media.jai.mlib.MlibRescaleOpImage, com.sun.media.jai.opimage.MinOpImage, com.sun.media.jai.mlib.MlibMultiplyOpImage, com.sun.media.jai.opimage.CopyOpImage, com.sun.media.jai.opimage.SubtractOpImage, com.sun.media.jai.mlib.MlibAddConstOpImage,
PointOpImage | abstract public class PointOpImage extends OpImage (Code) | | An abstract base class for image operators that require only the
(x, y) pixel from each source image in order to compute the
destination pixel (x, y).
PointOpImage is intended as a convenient
superclass for OpImage s that only need to look at each
destination pixel's corresponding source pixels. Some examples are
lookup, contrast adjustment, pixel arithmetic, and color space
conversion.
See Also: OpImage |
Constructor Summary | |
public | PointOpImage(Vector sources, ImageLayout layout, Map configuration, boolean cobbleSources) Constructor.
There must be at least one valid source supplied via the
sources argument. | public | PointOpImage(RenderedImage source, ImageLayout layout, Map configuration, boolean cobbleSources) Constructs a PointOpImage with one source image. | public | PointOpImage(RenderedImage source0, RenderedImage source1, ImageLayout layout, Map configuration, boolean cobbleSources) Constructs a PointOpImage with two source images. | public | PointOpImage(RenderedImage source0, RenderedImage source1, RenderedImage source2, ImageLayout layout, Map configuration, boolean cobbleSources) Constructs a PointOpImage with three source
images. |
Method Summary | |
public Raster | computeTile(int tileX, int tileY) Computes a tile. | public synchronized void | dispose() Disposes of any remaining tiles in the TileCache . | protected boolean | isColormapOperation() Indicates whether the operation is being effected directly on the
associated colormap. | final public Rectangle | mapDestRect(Rectangle destRect, int sourceIndex) Returns a conservative estimate of the region of a specific
source that is required in order to compute the pixels of a
given destination rectangle. | final public Rectangle | mapSourceRect(Rectangle sourceRect, int sourceIndex) Returns a conservative estimate of the destination region that
can potentially be affected by the pixels of a rectangle of a
given source. | protected void | permitInPlaceOperation() Causes a flag to be set to indicate that in-place operation should
be permitted if the image bounds, tile grid offset, tile dimensions,
and SampleModels of the source and destination images are compatible.
This method should be invoked in the constructor of the implementation
of a given operation only if that implementation is amenable to
in-place computation. |
PointOpImage | public PointOpImage(Vector sources, ImageLayout layout, Map configuration, boolean cobbleSources)(Code) | | Constructor.
There must be at least one valid source supplied via the
sources argument. However, there is no upper limit
on the number of sources this image may have.
The image's layout is encapsulated in the layout
argument. If the image bounds are supplied they must be contained
within the intersected source bounds which must be non-empty.
If the bounds are not supplied, they are calculated to be the
intersection of the bounds of all sources.
If no SampleModel is specified in the layout, a new
SampleModel will be created. This SampleModel
will have a number of bands equal to the minimum band count of all
sources and a depth which can accomodate the data of all sources.
The band count of sources which have an IndexColorModel
will be set to the number of components of the
IndexColorModel instead of to the number of bands of the
SampleModel .
In all cases, the layout is forwarded to the OpImage
constructor which sets the default layout values in the standard way.
Parameters: layout - The layout parameters of the destination image. Parameters: sources - The source images. 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: cobbleSources - true if computeRect() expectscontiguous sources. throws: IllegalArgumentException - If sources or anyobject in sources is null . throws: IllegalArgumentException - if sources does notcontain at least one element. throws: ClassCastException - If any object in sources is not a RenderedImage . throws: IllegalArgumentException - If combining the intersectedsource bounds with the user-specified bounds, if any,yields an empty rectangle, or the user-specified image boundsextends beyond the intersection of all the source bounds. since: JAI 1.1 |
PointOpImage | public PointOpImage(RenderedImage source, ImageLayout layout, Map configuration, boolean cobbleSources)(Code) | | Constructs a PointOpImage with one source image.
The image layout is computed as described in the constructor
taking a Vector of sources.
Parameters: layout - The layout parameters of the destination image. Parameters: source - The source image. 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: cobbleSources - Indicates whether computeRect() expects contiguous sources. throws: IllegalArgumentException - if source is null . since: JAI 1.1 |
PointOpImage | public PointOpImage(RenderedImage source0, RenderedImage source1, ImageLayout layout, Map configuration, boolean cobbleSources)(Code) | | Constructs a PointOpImage with two source images.
The image layout is computed as described in the constructor
taking a Vector of sources.
Parameters: layout - The layout parameters of the destination image. Parameters: source0 - The first source image. Parameters: source1 - The second source image. 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: cobbleSources - Indicates whether computeRect() expects contiguous sources. throws: IllegalArgumentException - if source0 orsource1 is null . since: JAI 1.1 |
PointOpImage | public PointOpImage(RenderedImage source0, RenderedImage source1, RenderedImage source2, ImageLayout layout, Map configuration, boolean cobbleSources)(Code) | | Constructs a PointOpImage with three source
images. The image layout is computed as described in the
constructor taking a Vector of sources.
Parameters: layout - The layout parameters of the destination image. Parameters: source0 - The first source image. Parameters: source1 - The second source image. Parameters: source2 - The third source image. 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: cobbleSources - Indicates whether computeRect() expects contiguous sources. throws: IllegalArgumentException - if source0 orsource1 or source2 isnull . since: JAI 1.1 |
computeTile | public Raster computeTile(int tileX, int tileY)(Code) | | Computes a tile. If source cobbling was requested at
construction time, the source tile boundaries are overlayed
onto the destination and computeRect(Raster[],
WritableRaster, Rectangle) is called for each of the
resulting regions. Otherwise, computeRect(PlanarImage[],
WritableRaster, Rectangle) is called once to compute the
entire active area of the tile.
The image bounds may be larger than the bounds of the
source image. In this case, samples for which there are no
corresponding sources are set to zero.
Parameters: tileX - The X index of the tile. Parameters: tileY - The Y index of the tile. |
dispose | public synchronized void dispose()(Code) | | Disposes of any remaining tiles in the TileCache .
If cache is non-null , in place operation
is enabled, and tileRecycler is non-null ,
then all tiles owned by this specific image are removed from the cache.
Subsequent to this super.dispose() is invoked.
since: JAI 1.1.2 |
isColormapOperation | protected boolean isColormapOperation()(Code) | | Indicates whether the operation is being effected directly on the
associated colormap. This method will in general return
true if the image is the destination of a unary,
shift-invariant operation with an IndexColorModel equal
to that of its unique source.
When this method returns true the
computeTile() method in this class will return either
a copy of the corresponding region of the first source image or,
if the operation is being performed in place, the corresponding
tile of the first source image.
The implementation in this class always returns false .
since: JAI 1.1 |
mapDestRect | final public Rectangle mapDestRect(Rectangle destRect, int sourceIndex)(Code) | | Returns a conservative estimate of the region of a specific
source that is required in order to compute the pixels of a
given destination rectangle. The resulting Rectangle
is not clipped to the source image bounds.
Parameters: destRect - the Rectangle in source coordinates. Parameters: sourceIndex - the index of the source image. a Rectangle indicating the potentially affecteddestination region. throws: IllegalArgumentException - if sourceIndex isnegative or greater than the index of the last source. throws: IllegalArgumentException - if destRect isnull . |
mapSourceRect | final public Rectangle mapSourceRect(Rectangle sourceRect, int sourceIndex)(Code) | | Returns a conservative estimate of the destination region that
can potentially be affected by the pixels of a rectangle of a
given source. The resulting Rectangle is not
clipped to the destination image bounds.
Parameters: sourceRect - the Rectangle in source coordinates. Parameters: sourceIndex - the index of the source image. a Rectangle indicating the potentially affecteddestination region, or null if the region is unknown. throws: IllegalArgumentException - if sourceIndex isnegative or greater than the index of the last source. throws: IllegalArgumentException - if sourceRect isnull . |
permitInPlaceOperation | protected void permitInPlaceOperation()(Code) | | Causes a flag to be set to indicate that in-place operation should
be permitted if the image bounds, tile grid offset, tile dimensions,
and SampleModels of the source and destination images are compatible.
This method should be invoked in the constructor of the implementation
of a given operation only if that implementation is amenable to
in-place computation. Invocation of this method is a necessary but
not a sufficient condition for in-place computation actually to occur.
If the system property "javax.media.jai.PointOpImage.InPlace" is equal
to the string "false" in a case-insensitive fashion then in-place
operation will not be permitted.
|
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)
|
|
|