org.geotools.image.io.mosaic
Class LargeTile

java.lang.Object
  extended by org.geotools.image.io.mosaic.Tile
      extended by org.geotools.image.io.mosaic.LargeTile
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable<Tile>

public class LargeTile
extends Tile

A tile with larger capacity than the default Tile implementation. Instances of this class usually don't need to be created, since the whole purpose of tile is to represent a small portion of an image. However it is needed in some case, typically to represent an image before a mosaic is built from it.

Version:
$Id: LargeTile.java 31996 2008-12-11 14:33:48Z desruisseaux $
Author:
Martin Desruisseaux
See Also:
Serialized Form

Constructor Summary
LargeTile(javax.imageio.spi.ImageReaderSpi provider, java.lang.Object input, int imageIndex, java.awt.Point location, java.awt.Dimension subsampling)
          Creates a tile for the given provider, input and location.
LargeTile(javax.imageio.spi.ImageReaderSpi provider, java.lang.Object input, int imageIndex, java.awt.Rectangle region)
          Creates a tile for the given region with default subsampling.
LargeTile(javax.imageio.spi.ImageReaderSpi provider, java.lang.Object input, int imageIndex, java.awt.Rectangle region, java.awt.geom.AffineTransform gridToCRS)
          Creates a tile for the given provider, input and "grid to real world" transform.
LargeTile(javax.imageio.spi.ImageReaderSpi provider, java.lang.Object input, int imageIndex, java.awt.Rectangle region, java.awt.Dimension subsampling)
          Creates a tile for the given provider, input and region.
 
Method Summary
 java.awt.Rectangle getRegion()
          Returns the upper-left corner in the destination image, with the image size.
 
Methods inherited from class org.geotools.image.io.mosaic.Tile
compareTo, equals, getFormatName, getGridToCRS, getImageIndex, getImageReader, getImageReader, getImageReaderSpi, getInput, getInputName, getLocation, getSubsampling, getSubsamplingFloor, hashCode, toString, writeTable
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

LargeTile

public LargeTile(javax.imageio.spi.ImageReaderSpi provider,
                 java.lang.Object input,
                 int imageIndex,
                 java.awt.Point location,
                 java.awt.Dimension subsampling)
          throws java.lang.IllegalArgumentException
Creates a tile for the given provider, input and location. See super-class constructor for details.

Parameters:
provider - The image reader provider to use, or null.
input - The input to be given to the image reader.
imageIndex - The image index to be given to the image reader for reading this tile.
location - The upper-left corner in the destination image.
subsampling - The subsampling relative to the tile having the finest resolution, or null.
Throws:
java.lang.IllegalArgumentException - If a required argument is null or some argument has an invalid value.

LargeTile

public LargeTile(javax.imageio.spi.ImageReaderSpi provider,
                 java.lang.Object input,
                 int imageIndex,
                 java.awt.Rectangle region,
                 java.awt.Dimension subsampling)
          throws java.lang.IllegalArgumentException
Creates a tile for the given provider, input and region. See super-class constructor for details.

Parameters:
provider - The image reader provider to use, or null.
input - The input to be given to the image reader.
imageIndex - The image index to be given to the image reader for reading this tile.
region - The region in the destination image.
subsampling - The subsampling relative to the tile having the finest resolution, or null.
Throws:
java.lang.IllegalArgumentException - If a required argument is null or some argument has an invalid value.

LargeTile

public LargeTile(javax.imageio.spi.ImageReaderSpi provider,
                 java.lang.Object input,
                 int imageIndex,
                 java.awt.Rectangle region,
                 java.awt.geom.AffineTransform gridToCRS)
          throws java.lang.IllegalArgumentException
Creates a tile for the given provider, input and "grid to real world" transform. See super-class constructor for details.

Parameters:
provider - The image reader provider to use, or null.
input - The input to be given to the image reader.
imageIndex - The image index to be given to the image reader for reading this tile.
region - The region in the destination image, or null.
gridToCRS - The "grid to real world" transform.
Throws:
java.lang.IllegalArgumentException - If a required argument is null or some argument has an invalid value.

LargeTile

public LargeTile(javax.imageio.spi.ImageReaderSpi provider,
                 java.lang.Object input,
                 int imageIndex,
                 java.awt.Rectangle region)
          throws java.lang.IllegalArgumentException
Creates a tile for the given region with default subsampling. See super-class constructor for details.

Parameters:
provider - The image reader provider to use, or null.
input - The input to be given to the image reader.
imageIndex - The image index to be given to the image reader for reading this tile.
region - The region in the destination image.
Throws:
java.lang.IllegalArgumentException - If a required argument is null or some argument has an invalid value.
Method Detail

getRegion

public java.awt.Rectangle getRegion()
                             throws java.io.IOException
Returns the upper-left corner in the destination image, with the image size.

Overrides:
getRegion in class Tile
Returns:
The region in the destination image.
Throws:
java.io.IOException - if it was necessary to fetch the image dimension from the reader and this operation failed.
See Also:
IIOParam.setSourceRegion(java.awt.Rectangle)


Copyright © 1996-2010 Geotools. All Rights Reserved.