org.opengis.display.canvas
Interface CanvasState

Show UML class diagram

public interface CanvasState

Describe the current state of a canvas. The information contained by instances of this interface should only describe the viewing area or volume of the canvas and should not contain any state information regarding the data contained within it.

When an instance of this class is returned from Canvas methods, a "snapshot" of the current state of the canvas is taken and the values will never change (even if the canvas changes state).

Since:
GeoAPI 2.2

Method Summary
 DirectPosition getCenter()
          Returns the position of the center point of the canvas.
 CoordinateReferenceSystem getDisplayCRS()
          Returns the Coordinate Reference System associated with the display of the canvas.
 MathTransform getDisplayToObjectiveTransform()
          Returns the transform from display to objective CRS.
 CoordinateReferenceSystem getObjectiveCRS()
          Returns the "real world" Coordinate Reference System.
 MathTransform getObjectiveToDisplayTransform()
          Returns the transform from objective to display CRS.
 InternationalString getTitle()
          Returns the title of the canvas.
 

Method Detail

getTitle

InternationalString getTitle()
Returns the title of the canvas.

Returns:
The canvas title.
See Also:
CanvasController.setTitle(org.opengis.util.InternationalString)

getCenter

DirectPosition getCenter()
Returns the position of the center point of the canvas. The coordinate shall be in objective CRS.

Returns:
The center point in objective CRS.
See Also:
CanvasController.setCenter(org.opengis.geometry.DirectPosition)

getObjectiveCRS

CoordinateReferenceSystem getObjectiveCRS()
Returns the "real world" Coordinate Reference System. This is typically a projected CRS using linear units like metre. Graphic data are projected to this CRS before to be display.

Returns:
The "real world" Coordinate Reference System.
See Also:
CanvasController.setObjectiveCRS(org.opengis.referencing.crs.CoordinateReferenceSystem)

getDisplayCRS

CoordinateReferenceSystem getDisplayCRS()
Returns the Coordinate Reference System associated with the display of the canvas. The display CRS has a Coordinate System corresponding to the geometry of the display device. For example flat video monitors are associated to cartesian CS while planetarium may be associated to spherical CS. Axis units are typically (but are not restricted to) some linear units like 1/72 of inch.

This CRS can be implemented as a derived CRS based on the objective CRS. In such implementations, the display CRS changes after every zoom or translation action.

Returns:
The display Coordinate Reference System.

getObjectiveToDisplayTransform

MathTransform getObjectiveToDisplayTransform()
Returns the transform from objective to display CRS. If the later is implemented as a derived CRS, then this transform shall be equal to the following:
getDisplayCRS().getConversionFromBase().getMathTransform()
This transform is typically (but is not required to be) affine. When this transform is affine, then the scale factors (the coefficients on the matrix diagonal when there is no rotation or shear) are the map scale along the corresponding axis.

Returns:
The transform from objective to display CRS.

getDisplayToObjectiveTransform

MathTransform getDisplayToObjectiveTransform()
Returns the transform from display to objective CRS. This is the inverse of the objective to display transform.

Returns:
The transform from display to objective CRS.


Copyright © 1994-2013 Open Geospatial Consortium. All Rights Reserved.