org.geotools.ct
Interface MathTransform2D

All Superinterfaces:
MathTransform
All Known Implementing Classes:
MapProjection

Deprecated. Replaced by MathTransform2D in the org.opengis.referencing.operation package.

public interface MathTransform2D
extends MathTransform

Transforms two-dimensional coordinate points. CoordinateTransformation.getMathTransform() may returns instance of this interface when source and destination coordinate systems are both two dimensional. MathTransform2D extends MathTransform by adding some methods for easier interoperability with Java2D. If the transformation is affine, then MathTransform shall be an immutable instance of AffineTransform.

Version:
1.00
Author:
OpenGIS (www.opengis.org), Martin Desruisseaux
See Also:
AffineTransform, PerspectiveTransform

Field Summary
static MathTransform2D IDENTITY
          Deprecated. The two dimensional identity transform.
 
Method Summary
 java.awt.Shape createTransformedShape(java.awt.Shape shape)
          Deprecated. Transform the specified shape.
 Matrix derivative(java.awt.geom.Point2D point)
          Deprecated. Gets the derivative of this transform at a point.
 java.awt.geom.Point2D transform(java.awt.geom.Point2D ptSrc, java.awt.geom.Point2D ptDst)
          Deprecated. Transforms the specified ptSrc and stores the result in ptDst.
 
Methods inherited from interface org.geotools.ct.MathTransform
derivative, getDimSource, getDimTarget, inverse, isIdentity, transform, transform, transform
 

Field Detail

IDENTITY

public static final MathTransform2D IDENTITY
Deprecated. 
The two dimensional identity transform.

Method Detail

transform

public java.awt.geom.Point2D transform(java.awt.geom.Point2D ptSrc,
                                       java.awt.geom.Point2D ptDst)
                                throws org.opengis.referencing.operation.TransformException
Deprecated. 
Transforms the specified ptSrc and stores the result in ptDst. If ptDst is null, a new Point2D object is allocated and then the result of the transformation is stored in this object. In either case, ptDst, which contains the transformed point, is returned for convenience. If ptSrc and ptDst are the same object, the input point is correctly overwritten with the transformed point.

Parameters:
ptSrc - the specified coordinate point to be transformed.
ptDst - the specified coordinate point that stores the result of transforming ptSrc, or null.
Returns:
the coordinate point after transforming ptSrc and stroring the result in ptDst.
Throws:
org.opengis.referencing.operation.TransformException - if the point can't be transformed.

createTransformedShape

public java.awt.Shape createTransformedShape(java.awt.Shape shape)
                                      throws org.opengis.referencing.operation.TransformException
Deprecated. 
Transform the specified shape. This method may replace straight lines by quadratic curves when applicable. It may also do the opposite (replace curves by straight lines). The returned shape doesn't need to have the same number of points than the original shape.

Parameters:
shape - Shape to transform.
Returns:
Transformed shape, or shape if this transform is the identity transform.
Throws:
org.opengis.referencing.operation.TransformException - if a transform failed.

derivative

public Matrix derivative(java.awt.geom.Point2D point)
                  throws org.opengis.referencing.operation.TransformException
Deprecated. 
Gets the derivative of this transform at a point. The derivative is the matrix of the non-translating portion of the approximate affine map at the point.

Parameters:
point - The coordinate point where to evaluate the derivative. Null value is accepted only if the derivative is the same everywhere. For example affine transform accept null value since they produces identical derivative no matter the coordinate value. But most map projection will requires a non-null value.
Returns:
The derivative at the specified point as a 2×2 matrix. This method never returns an internal object: changing the matrix will not change the state of this math transform.
Throws:
java.lang.NullPointerException - if the derivative dependents on coordinate and point is null.
org.opengis.referencing.operation.TransformException - if the derivative can't be evaluated at the specified point.


Copyright © GeoTools. All Rights Reserved.