Marble::GeoSceneMercatorTileProjection

Search for usage in LXR

Marble::GeoSceneMercatorTileProjection Class Reference

#include <GeoSceneMercatorTileProjection.h>

Inheritance diagram for Marble::GeoSceneMercatorTileProjection:

Public Member Functions

 GeoSceneMercatorTileProjection ()
 
GeoDataLatLonBox geoCoordinates (const TileId &tileId) const
 
GeoDataLatLonBox geoCoordinates (int zoomLevel, int x, int y) const override
 
virtual GeoDataLatLonBox geoCoordinates (int zoomLevel, int x, int y) const=0
 
QRect tileIndexes (const GeoDataLatLonBox &latLonBox, int zoomLevel) const override
 
GeoSceneAbstractTileProjection::Type type () const override
 
- Public Member Functions inherited from Marble::GeoSceneAbstractTileProjection
 GeoSceneAbstractTileProjection ()
 
GeoDataLatLonBox geoCoordinates (const TileId &tileId) const
 
int levelZeroColumns () const
 
int levelZeroRows () const
 
void setLevelZeroColumns (int levelZeroColumns)
 
void setLevelZeroRows (int levelZeroRows)
 

Additional Inherited Members

- Public Types inherited from Marble::GeoSceneAbstractTileProjection
enum  Type { Equirectangular, Mercator }
 

Detailed Description

Converts the x and y indices of tiles to and from geo coordinates.

For tiles of maps in Mercator projection.

Tiles do have the same width and the same height per zoomlevel. The number of tiles per dimension is twice that of the previous lower zoomlevel. The indexing is done in x dimension eastwards, with the first tiles beginning at -180 degree and an x value of 0 and the last tiles ending at +180 degree, in y dimension southwards with the first tiles beginning at +85.05113 degree and a y value of 0 and the last tiles ending at -85.05113 degree.

NOTE: The method tileIndexes() handles any latitude value >= +85.0 degree as exactly +85.0 degree and any latitude value <= -85.0 as exactly -85.0 degree. So for higher zoomlevels the outermost tiles will be masked by that and not included in any results.

Definition at line 30 of file GeoSceneMercatorTileProjection.h.

Constructor & Destructor Documentation

◆ GeoSceneMercatorTileProjection()

Marble::GeoSceneMercatorTileProjection::GeoSceneMercatorTileProjection ( )

Construct a new GeoSceneMercatorTileProjection.

Definition at line 16 of file GeoSceneMercatorTileProjection.cpp.

Member Function Documentation

◆ geoCoordinates() [1/3]

GeoDataLatLonBox Marble::GeoSceneAbstractTileProjection::geoCoordinates

Get the boundary geo coordinates corresponding to a tile.

If tildId has values out-of-bounds, the behaviour is undefined.

Parameters
tileIdthe id of the tile
Returns
geographic bounding box covered by the given tile

Definition at line 60 of file GeoSceneAbstractTileProjection.cpp.

◆ geoCoordinates() [2/3]

GeoDataLatLonBox Marble::GeoSceneMercatorTileProjection::geoCoordinates ( int  zoomLevel,
int  x,
int  y 
) const
overridevirtual

◆ geoCoordinates() [3/3]

virtual GeoDataLatLonBox Marble::GeoSceneAbstractTileProjection::geoCoordinates

Get the boundary geo coordinates corresponding to a tile.

If x, y or zoomLevel have values out-of-bounds, the behaviour is undefined.

Parameters
zoomLevelthe zoomlevel of the tile
xthe x index of the tile
ythe y index of the tile
Returns
geographic bounding box covered by the given tile

◆ tileIndexes()

QRect Marble::GeoSceneMercatorTileProjection::tileIndexes ( const GeoDataLatLonBox latLonBox,
int  zoomLevel 
) const
overridevirtual

◆ type()

GeoSceneAbstractTileProjection::Type Marble::GeoSceneMercatorTileProjection::type ( ) const
overridevirtual

The documentation for this class was generated from the following files:
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Sun Nov 27 2022 03:55:00 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.