public class Projection
extends java.lang.Object
Constructor and Description |
---|
Projection(MapContext mapContext) |
Modifier and Type | Method and Description |
---|---|
double |
distanceBetween(GeoPoint geopt1,
GeoPoint geopt2)
Deprecated.
Use distanceBetween(LatLng, LatLng) instead.
|
double |
distanceBetween(LatLng p1,
LatLng p2) |
GeoPoint |
fromPixels(int x,
int y)
Deprecated.
Use fromScreenLocation instead.
|
LatLng |
fromScreenLocation(android.graphics.Point screenPoint) |
int |
getLatitudeSpan()
返回当前地图视图范围的纬度跨度(从地图的上边缘到下边缘),单位:十进制的度×1,000,000,即微度(度 * 1E6)。
|
int |
getLongitudeSpan()
返回当前地图视图范围的经度跨度(从地图的左边缘到右边缘),单位:十进制的度×1,000,000,即微度(度 * 1E6)。
|
float |
getScalePerPixel()
获取比例尺
|
VisibleRegion |
getVisibleRegion() |
float |
metersToEquatorPixels(float meters) |
float |
metersToPixels(double latitude,
double meters) |
android.graphics.Point |
toPixels(GeoPoint geopoint,
android.graphics.Point point)
Deprecated.
Use toScreenLocation instead.
|
android.graphics.Point |
toScreenLocation(LatLng location) |
public LatLng fromScreenLocation(android.graphics.Point screenPoint)
public android.graphics.Point toScreenLocation(LatLng location)
public VisibleRegion getVisibleRegion()
public float metersToEquatorPixels(float meters)
public float metersToPixels(double latitude, double meters)
public int getLatitudeSpan()
public int getLongitudeSpan()
public float getScalePerPixel()
public double distanceBetween(GeoPoint geopt1, GeoPoint geopt2)
geopt1
- 坐标点geopt2
- 坐标点public GeoPoint fromPixels(int x, int y)
x
- x坐标y
- y坐标public android.graphics.Point toPixels(GeoPoint geopoint, android.graphics.Point point)
geopoint
- 经纬度坐标point
- 投影后的像素坐标