Package hec.map.crs

Class IdentityTransformImpl

java.lang.Object
hec.map.crs.IdentityTransformImpl
All Implemented Interfaces:
Transform

public class IdentityTransformImpl extends Object implements Transform
This is a simple transform that transforms nothing at all. This is used if there is not a way to create a transform from one CRS to another. Such as one being null.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    transform(double[] srcXPts, double[] srcYPts, int srcOffset, double[] dstXPts, double[] dstYPts, int dstOffset, int numPts)
    Transforms a list of coordinate point ordinal values.
    double[]
    transform(double srcXPt, double srcYPt, double[] returnPts)
    Transforms a list of coordinate point ordinal values.
    void
    transform(float[] srcXPts, float[] srcYPts, int srcOffset, float[] dstXPts, float[] dstYPts, int dstOffset, int numPts)
    Transforms a list of coordinate point ordinal values.
    float[]
    transform(float srcXPt, float srcYPt, float[] returnPts)
    Transforms a list of coordinate point ordinal values.
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • IdentityTransformImpl

      public IdentityTransformImpl()
  • Method Details

    • transform

      public void transform(double[] srcXPts, double[] srcYPts, int srcOffset, double[] dstXPts, double[] dstYPts, int dstOffset, int numPts) throws CRSException
      Description copied from interface: Transform
      Transforms a list of coordinate point ordinal values. This method is provided for efficiently transforming many points.
      Specified by:
      transform in interface Transform
      Parameters:
      srcXPts - the array containing source x points.
      srcYPts - the array containing source y points.
      srcOffset - the offset to the first point to be transformed in the source arrays.
      dstXPts - the array into which the transformed point X coordinates are returned. May be the same than srcXPts.
      dstYPts - the array into which the transformed point Y coordinates are returned. May be the same than srcYPts.
      dstOffset - the offset to the location of the first transformed point that is stored in the destination array.
      numPts - the number of point objects to be transformed.
      Throws:
      CRSException
    • transform

      public void transform(float[] srcXPts, float[] srcYPts, int srcOffset, float[] dstXPts, float[] dstYPts, int dstOffset, int numPts) throws CRSException
      Description copied from interface: Transform
      Transforms a list of coordinate point ordinal values. This method is provided for efficiently transforming many points.
      Specified by:
      transform in interface Transform
      Parameters:
      srcXPts - the array containing source x points.
      srcYPts - the array containing source y points.
      srcOffset - the offset to the first point to be transformed in the source arrays.
      dstXPts - the array into which the transformed point X coordinates are returned. May be the same than srcXPts.
      dstYPts - the array into which the transformed point Y coordinates are returned. May be the same than srcYPts.
      dstOffset - the offset to the location of the first transformed point that is stored in the destination array.
      numPts - the number of point objects to be transformed.
      Throws:
      CRSException
    • transform

      public Image transform(RenderedImage rImage, Rectangle2D extent) throws CRSException
      Specified by:
      transform in interface Transform
      Throws:
      CRSException
    • transform

      public double[] transform(double srcXPt, double srcYPt, double[] returnPts)
      Description copied from interface: Transform
      Transforms a list of coordinate point ordinal values.

      Specified by:
      transform in interface Transform
      Parameters:
      srcXPt - the x points.
      srcYPt - the y points.
      returnPts - an array that contains the transformed points. This can be null or undersized and if it is, a new array is created to hold the return points.

      Returns:
      an array that contains the output point. [0] is the xpoint, [1] is the ypoint. This will be the same array if a valid value is passed in the returnPts
    • transform

      public float[] transform(float srcXPt, float srcYPt, float[] returnPts)
      Description copied from interface: Transform
      Transforms a list of coordinate point ordinal values.

      Specified by:
      transform in interface Transform
      Parameters:
      srcXPt - the x points.
      srcYPt - the y points.
      returnPts - an array that contains the transformed points. This can be null or undersized and if it is, a new array is created to hold the return points.

      Returns:
      an array that contains the output point. [0] is the xpoint, [1] is the ypoint. This will be the same array if a valid value is passed in the returnPts