Documentation of 'visad.georef.TrivialMapProjection' Java class
TrivialMapProjection
visad.georef

Class TrivialMapProjection

  • All Implemented Interfaces:
    java.io.Serializable


    public class TrivialMapProjection
    extends MapProjection
    A trivial implementation for a MapProjection which provides an identity coordinate system with a default bounding box. This is useful for defining an area in LatLon or LonLat space with a bounding box. What goes in, comes right back out.
    See Also:
    Serialized Form
    • Constructor Detail

      • TrivialMapProjection

        public TrivialMapProjection()
                             throws VisADException
        Create a MapProjection that just returns the input tuple. Default Map area is set to be from (-180,-90) to (180, 90)
        Throws:
        VisADException - reference does not contain Latitude/Longitude or couldn't create the necessary VisAD object
      • TrivialMapProjection

        public TrivialMapProjection(RealTupleType reference)
                             throws VisADException
        Create a MapProjection that just returns the input tuple.
        Parameters:
        reference - reference RealTupleType
        Throws:
        VisADException - reference does not contain Latitude/Longitude or couldn't create the necessary VisAD object
      • TrivialMapProjection

        public TrivialMapProjection(RealTupleType type,
                                    java.awt.geom.Rectangle2D bounds)
                             throws VisADException
        Create a MapProjection that just returns the input tuple.
        Parameters:
        type - reference RealTupleType
        bounds - rectangle bounds
        Throws:
        VisADException - reference does not contain Latitude/Longitude or couldn't create the necessary VisAD object
    • Method Detail

      • toReference

        public double[][] toReference(double[][] tuple)
                               throws VisADException
        Transform to the reference coordinates
        Specified by:
        toReference in class CoordinateSystem
        Parameters:
        tuple - array of values
        Returns:
        input array
        Throws:
        VisADException - tuple is null or wrong dimension
      • fromReference

        public double[][] fromReference(double[][] refTuple)
                                 throws VisADException
        Transform from the reference coordinates
        Specified by:
        fromReference in class CoordinateSystem
        Parameters:
        refTuple - array of values
        Returns:
        input array
        Throws:
        VisADException - tuple is null or wrong dimension
      • toReference

        public float[][] toReference(float[][] tuple)
                              throws VisADException
        Transform to the reference coordinates
        Overrides:
        toReference in class CoordinateSystem
        Parameters:
        tuple - array of values
        Returns:
        input array
        Throws:
        VisADException - tuple is null or wrong dimension
      • fromReference

        public float[][] fromReference(float[][] refTuple)
                                throws VisADException
        Transform from the reference coordinates
        Overrides:
        fromReference in class CoordinateSystem
        Parameters:
        refTuple - array of values
        Returns:
        input array
        Throws:
        VisADException - tuple is null or wrong dimension
      • equals

        public boolean equals(java.lang.Object o)
        See if the object in question is equal to this CoordinateSystem. The two objects are equal if they are the same object or if they are both TrivialMapProjection and have the same dimension.
        Specified by:
        equals in class CoordinateSystem
        Parameters:
        o - Object in question
        Returns:
        true if they are considered equal, otherwise false.
      • getDefaultMapArea

        public java.awt.geom.Rectangle2D getDefaultMapArea()
        Get a reasonable bounding box in this coordinate system. MapProjections are typically specific to an area of the world; there's no bounding box that works for all projections so each subclass must implement this method. For example, the bounding box for a satellite image MapProjection might have an upper left corner of (0,0) and the width and height of the Rectangle2D would be the number of elements and lines, respectively.
        Specified by:
        getDefaultMapArea in class MapProjection
        Returns:
        the bounding box of the MapProjection

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.