Interface Projection

All Known Subinterfaces:
TileSource
All Known Implementing Classes:
MercatorProjection, OpenStreetMapTileSource, OpenTopoMapTileSource, TileSourceSupport

public interface Projection
This class is responsible for converting (latitude, longitude) into rectilinear (x,y) coordinates (to be used by a map).
Author:
Fabrizio Giudici
  • Method Details

    • coordinatesToMapPoint

      @Nonnull MapPoint coordinatesToMapPoint(@Nonnull MapCoordinates coordinates, double zoom)
      Returns a MapPoint converted from the given coordinates and zoom level..
      Parameters:
      coordinates - the coordinates to convert
      zoom - the zoom level
      Returns:
      a MapPoint converted from the given coordinates and zoom level
    • mapPointToCoordinates

      @Nonnull MapCoordinates mapPointToCoordinates(@Nonnull MapPoint mapPoint, double zoom)
      Returns MapCoordinates converted from the point coordinates and zoom level..
      Parameters:
      mapPoint - the point
      zoom - the zoom level
      Returns:
      MapCoordinates converted from the point coordinates and zoom level
    • metersPerPixel

      double metersPerPixel(@Nonnull MapCoordinates coordinates, double zoom)
      Returns the map scale (expressed in meters per pixel) at the given zoom level..
      Parameters:
      coordinates - coordinates
      zoom - the zoom level
      Returns:
      the map scale (expressed in meters per pixel) at the given zoom level