org.geotools.renderer.lite.gridcoverage2d
Class GridCoverageRenderer

java.lang.Object
  extended by org.geotools.renderer.lite.gridcoverage2d.GridCoverageRenderer

public final class GridCoverageRenderer
extends java.lang.Object

A helper class for rendering GridCoverage objects. Support for grid coverage SLD stylers is still limited.

Version:
$Id: GridCoverageRenderer.java 33831 2009-09-03 10:49:54Z simonegiannecchini $
Author:
Simone Giannecchini, Andrea Aime, Alessio Fabiani

Constructor Summary
GridCoverageRenderer(org.opengis.referencing.crs.CoordinateReferenceSystem destinationCRS, com.vividsolutions.jts.geom.Envelope envelope, java.awt.Rectangle screenSize)
          Deprecated. Use GridCoverageRenderer(CoordinateReferenceSystem, Envelope, Rectangle, AffineTransform, RenderingHints) instead
GridCoverageRenderer(org.opengis.referencing.crs.CoordinateReferenceSystem destinationCRS, com.vividsolutions.jts.geom.Envelope envelope, java.awt.Rectangle screenSize, java.awt.geom.AffineTransform worldToScreen)
          Creates a new GridCoverageRenderer object.
GridCoverageRenderer(org.opengis.referencing.crs.CoordinateReferenceSystem destinationCRS, com.vividsolutions.jts.geom.Envelope envelope, java.awt.Rectangle screenSize, java.awt.geom.AffineTransform worldToScreen, java.awt.RenderingHints java2dHints)
          Creates a new GridCoverageRenderer object.
GridCoverageRenderer(org.opengis.referencing.crs.CoordinateReferenceSystem destinationCRS, com.vividsolutions.jts.geom.Envelope envelope, java.awt.Rectangle screenSize, java.awt.RenderingHints java2dHints)
          Deprecated. Use GridCoverageRenderer(CoordinateReferenceSystem, Envelope, Rectangle, AffineTransform, RenderingHints) instead
 
Method Summary
 void paint(java.awt.Graphics2D graphics, GridCoverage2D gridCoverage, RasterSymbolizer symbolizer)
          Paint this grid coverage.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

GridCoverageRenderer

public GridCoverageRenderer(org.opengis.referencing.crs.CoordinateReferenceSystem destinationCRS,
                            com.vividsolutions.jts.geom.Envelope envelope,
                            java.awt.Rectangle screenSize)
                     throws org.opengis.referencing.operation.TransformException,
                            java.awt.geom.NoninvertibleTransformException
Deprecated. Use GridCoverageRenderer(CoordinateReferenceSystem, Envelope, Rectangle, AffineTransform, RenderingHints) instead

Creates a new GridCoverageRenderer object.

Parameters:
destinationCRS - the CRS of the GridCoverage2D to render.
envelope - delineating the area to be rendered.
screenSize - at which we want to rendere the source GridCoverage2D.
worldToScreen - if not null and if it contains a rotation, this Affine Tranform is used directly to convert from world coordinates to screen coordinates. Otherwise, a standard GridToEnvelopeMapper is used to calculate the affine transform.
Throws:
org.opengis.referencing.operation.TransformException
java.awt.geom.NoninvertibleTransformException

GridCoverageRenderer

public GridCoverageRenderer(org.opengis.referencing.crs.CoordinateReferenceSystem destinationCRS,
                            com.vividsolutions.jts.geom.Envelope envelope,
                            java.awt.Rectangle screenSize,
                            java.awt.geom.AffineTransform worldToScreen)
                     throws org.opengis.referencing.operation.TransformException,
                            java.awt.geom.NoninvertibleTransformException
Creates a new GridCoverageRenderer object.

Parameters:
destinationCRS - the CRS of the GridCoverage2D to render.
envelope - delineating the area to be rendered.
screenSize - at which we want to rendere the source GridCoverage2D.
worldToScreen - if not null and if it contains a rotation, this Affine Tranform is used directly to convert from world coordinates to screen coordinates. Otherwise, a standard GridToEnvelopeMapper is used to calculate the affine transform.
Throws:
org.opengis.referencing.operation.TransformException
java.awt.geom.NoninvertibleTransformException

GridCoverageRenderer

public GridCoverageRenderer(org.opengis.referencing.crs.CoordinateReferenceSystem destinationCRS,
                            com.vividsolutions.jts.geom.Envelope envelope,
                            java.awt.Rectangle screenSize,
                            java.awt.RenderingHints java2dHints)
                     throws org.opengis.referencing.operation.TransformException,
                            java.awt.geom.NoninvertibleTransformException
Deprecated. Use GridCoverageRenderer(CoordinateReferenceSystem, Envelope, Rectangle, AffineTransform, RenderingHints) instead

Creates a new GridCoverageRenderer object.

Parameters:
destinationCRS - the CRS of the GridCoverage2D to render.
envelope - delineating the area to be rendered.
screenSize - at which we want to rendere the source GridCoverage2D.
java2dHints - to control this rendering process.
Throws:
org.opengis.referencing.operation.TransformException
java.awt.geom.NoninvertibleTransformException

GridCoverageRenderer

public GridCoverageRenderer(org.opengis.referencing.crs.CoordinateReferenceSystem destinationCRS,
                            com.vividsolutions.jts.geom.Envelope envelope,
                            java.awt.Rectangle screenSize,
                            java.awt.geom.AffineTransform worldToScreen,
                            java.awt.RenderingHints java2dHints)
                     throws org.opengis.referencing.operation.TransformException,
                            java.awt.geom.NoninvertibleTransformException
Creates a new GridCoverageRenderer object.

Parameters:
destinationCRS - the CRS of the GridCoverage2D to render.
envelope - delineating the area to be rendered.
screenSize - at which we want to rendere the source GridCoverage2D.
worldToScreen - if not null and if it contains a rotation, this Affine Tranform is used directly to convert from world coordinates to screen coordinates. Otherwise, a standard GridToEnvelopeMapper is used to calculate the affine transform.
java2dHints - to control this rendering process.
Throws:
org.opengis.referencing.operation.TransformException
java.awt.geom.NoninvertibleTransformException
Method Detail

paint

public void paint(java.awt.Graphics2D graphics,
                  GridCoverage2D gridCoverage,
                  RasterSymbolizer symbolizer)
           throws org.opengis.referencing.FactoryException,
                  org.opengis.referencing.operation.TransformException,
                  java.awt.geom.NoninvertibleTransformException
Paint this grid coverage. The caller must ensure that graphics has an affine transform mapping "real world" coordinates in the coordinate system given by #getCoordinateSystem.

Parameters:
graphics - the Graphics2D context in which to paint.
metaBufferedEnvelope -
Throws:
org.opengis.referencing.FactoryException
org.opengis.referencing.operation.TransformException
java.awt.geom.NoninvertibleTransformException
java.lang.Exception
java.lang.UnsupportedOperationException - if the transformation from grid to coordinate system in the GridCoverage is not an AffineTransform


Copyright © 1996-2010 Geotools. All Rights Reserved.