com.baidu.mapapi.map.GroundOverlay,定义在地图上绘制一个 Ground 覆盖物,继承自com.baidu.mapapi.map.Overlay
字段概要
方法概要
限定符和类型 | 方法和说明 |
---|---|
float | getAnchorX()
获取 ground 覆盖物水平方向锚点比例
|
float | getAnchorY()
获取 ground 覆盖物垂直方向锚点比例
|
LatLngBounds | getBounds()
获取 ground 覆盖物地理坐标范围
|
int | getHeight()
获取 ground 覆盖物的高度,单位:米
|
BitmapDescriptor | getImage()
获取 ground 覆盖物的图片信息
|
LatLng | getPosition()
获取 ground 覆盖物位置信息
|
float | getTransparency()
获取 ground 覆盖物透明度
|
int | getWidth()
获取 ground 覆盖物的宽度,单位:米
|
void | setAnchor(float anchorX, float anchorY)
当使用 setPosition() 方式设置覆盖物地理位置时,设置 ground 覆盖物的锚点比例,默认为 0.5f,水平与垂直方向都居中对齐
|
void | setDimensions(int width)
设置 ground 覆盖物的宽度,单位:米, 高度按图片宽高比例
|
void | setDimensions(int width, int height)
设置 ground 覆盖物的宽度和高度,单位:米
|
void | setImage(BitmapDescriptor image)
设置 Ground 覆盖物的图片信息
|
void | setPosition(LatLng latLng)
设置 Ground 覆盖物位置信息方式一,与
setDimensions(int, int) 配合使用
|
void | setPositionFromBounds(LatLngBounds bounds)
设置 ground 覆盖物的位置信息方式二,设置西南与东北坐标范围
|
void | setTransparency(float transparency)
设置 ground 覆盖物透明度,默认为 1.0f
|
从类继承的方法 com.baidu.mapapi.map.Overlay
getExtraInfo, getZIndex, isVisible, remove, setExtraInfo, setVisible, setZIndex