AI-generated Key Takeaways
-
Projection is a class used to translate between on-screen locations in screen pixels relative to the top left of the map and geographic coordinates (LatLng) on the Earth's surface.
-
The
fromScreenLocationmethod returns the geographic location (LatLng) corresponding to a given screen location (Point). -
The
getVisibleRegionmethod gets a projection of the viewing frustum for converting between screen coordinates and geographical coordinates. -
The
toScreenLocationmethod returns a screen location (Point) that corresponds to a given geographical coordinate (LatLng).
A projection is used to translate between on screen location and geographic coordinates on
the surface of the Earth ( LatLng
). Screen
location is in screen pixels (not display pixels) with respect to the top left corner of the
map (and not necessarily of the whole screen).
Public Method Summary
| LatLng | fromScreenLocation
( Point
point)
Returns the geographic location that corresponds to a screen location.
|
| VisibleRegion | getVisibleRegion
()
Gets a projection of the viewing frustum for converting between screen
coordinates and geo-latitude/longitude coordinates.
|
| Point |
Inherited Method Summary
Public Methods
public LatLng fromScreenLocation ( Point point)
Returns the geographic location that corresponds to a screen location. The screen location is specified in screen pixels (not display pixels) relative to the top left of the map (not the top left of the whole screen).
Parameters
Returns
- The
LatLngcorresponding to thepointon the screen, ornullif the ray through the given screen point does not intersect the ground plane (this might be the case if the map is heavily tilted).
public VisibleRegion getVisibleRegion ()
Gets a projection of the viewing frustum for converting between screen coordinates and geo-latitude/longitude coordinates.
Returns
- The projection of the viewing frustum in its current state.

