/** * Adds a tile to the cache. * * @param owner The <code>RenderedImage</code> that the tile belongs to. * @param tileX The X index of the tile in the owner's tile grid. * @param tileY The Y index of the tile in the owner's tile grid. * @param tile A <code>Raster</code> containing the tile data. */ public void add(RenderedImage owner, int tileX, int tileY, Raster tile) { add(owner, tileX, tileY, tile, null); }
/** * Adds an array of tiles to the tile cache. * * @param owner The <code>RenderedImage</code> that the tile belongs to. * @param tileIndices An array of <code>Point</code>s containing the * <code>tileX</code> and <code>tileY</code> indices for each tile. * @param tiles The array of tile <code>Raster</code>s containing tile data. * @param tileCacheMetric Object which provides an ordering metric * associated with the <code>RenderedImage</code> owner. * @since JAI 1.1 */ public void addTiles(RenderedImage owner, Point[] tileIndices, Raster[] tiles, Object tileCacheMetric) { for (int i = 0; i < tileIndices.length; i++) { Point tileIndex = tileIndices[i]; add(owner, tileIndex.x, tileIndex.y, tiles[i], tileCacheMetric); } }