5
如何将标记的InfoWindows定位点重置为始终位于顶部中间?问题在于锚点随标记一起旋转。安卓谷歌地图InfoWindow标记旋转后的定位点
static final LatLng PERTH = new LatLng(-31.90, 115.86);
Marker marker = mMap.addMarker(new MarkerOptions()
.position(PERTH)
.anchor(0.5,0.5)
.rotation(90.0)
.infoWindowAnchor(0.5,0));
//Update marker with new data (position and direction angle)
var angle = 130.0;
marker.setPosition(new LatLng(-30.20, 113.27));
marker.setRotation(angle);
marker.setInfoWindowAnchor(x,y); // how to calculate these values?
一些解释会很好 –
什么是可变角度?如何达到像130.0这样的特定值? – Madhan